Google

Go to the first, previous, next, last section, table of contents.


newstruct

newstruct(name)
:: ¹½Â¤ÂÎ̾¤¬ name¤Î¹½Â¤ÂΤòÀ¸À®¤¹¤ë.
return
¹½Â¤ÂÎ
name
ʸ»úÎó
  • ̾Á°¤¬ name ¤Ç¤¢¤ë¹½Â¤ÂΤòÀ¸À®¤¹¤ë.
  • ¤¢¤é¤«¤¸¤á, name ¤Ê¤ë¹½Â¤ÂΤ¬ÄêµÁ¤µ¤ì¤Æ¤¤¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤.
  • ¹½Â¤ÂΤγƥá¥ó¥Ð¤Ï±é»»»Ò -> ¤Ë¤è¤ê̾Á°¤Ç¥¢¥¯¥»¥¹¤¹¤ë. ¥á¥ó¥Ð¤¬¹½Â¤ÂΤξì¹ç, ¹¹¤Ë -> ¤Ë¤è¤ë»ØÄê¤ò³¤±¤ë¤³¤È¤¬¤Ç¤­¤ë.
[0] struct list {h,t};    
0
[1] A=newstruct(list);
{0,0}
[2] A->t = newstruct(list);
{0,0}
[3] A; 
{0,{0,0}}
[4] A->h = 1;
1
[5] A->t->h = 2;
2
[6] A->t->t = 3;
3
[7] A;
{1,{2,3}}
»²¾È
section arfreg, section ¹½Â¤ÂÎÄêµÁ


Go to the first, previous, next, last section, table of contents.