質問編集履歴

1

2015/09/06 15:51

投稿

reotantan
reotantan

スコア295

test CHANGED
File without changes
test CHANGED
@@ -15,3 +15,67 @@
15
15
  ```
16
16
 
17
17
  タグがついていないものとついているもので書き方が違い戸惑っています。
18
+
19
+
20
+
21
+ 追記
22
+
23
+
24
+
25
+ typedefで文字を省略できるとあったのですが、これは
26
+
27
+ オブジェクトの前にstruct~と書かなくていいという意味ですか?
28
+
29
+ そんなにたいした文字量を省略しているわけではないと思ったのですが、
30
+
31
+ なぜtypedef stuctを使うのでしょうか
32
+
33
+
34
+
35
+ typedef struct
36
+
37
+ {
38
+
39
+ ~
40
+
41
+ }student;
42
+
43
+
44
+
45
+ int main(void){
46
+
47
+ student sanaka={~};
48
+
49
+ }
50
+
51
+
52
+
53
+ student型の構造体を作り、さなかというオブジェクトをつくった。
54
+
55
+
56
+
57
+ ーーーーーーーーーーーーーー
58
+
59
+
60
+
61
+ struct gstudent
62
+
63
+ {
64
+
65
+ ~
66
+
67
+ };
68
+
69
+
70
+
71
+ int main(void)
72
+
73
+ {
74
+
75
+ struct gstudent sanaka;
76
+
77
+ }
78
+
79
+
80
+
81
+ gstudent型の構造体をつくり、さなかというオブジェクトをつくった。