質問するログイン新規登録

質問編集履歴

1

main関数を追加しました。

2020/06/04 01:16

投稿

VanS
VanS

スコア7

title CHANGED
File without changes
body CHANGED
@@ -50,9 +50,44 @@
50
50
 
51
51
  }
52
52
 
53
+ int main(void)
54
+ {
55
+ int select,n,data;
56
+
57
+ LIST header;
58
+ header.next=NULL;
59
+
60
+ printf("いずれの関数を利用しますか?\n0..挿入/1..削除/2..分断/3..連結:");
61
+ scanf("%d",&select);
53
62
 
63
+ switch(select){
64
+ case 0:
65
+ printf("何番目に挿入しますか?:");scanf("%d",&n);
66
+ printf("挿入するデータを入力してください。:");scanf("%d",&data);
67
+
68
+ insert(header,n,data);
69
+
70
+ break;
71
+
72
+
73
+ case 1:
74
+ break;
75
+
76
+ case 2:
77
+ break;
78
+
79
+
80
+ case 3:
81
+ break;
82
+ }
83
+ return 0;
84
+
85
+ }
54
86
 
55
87
 
88
+
89
+
90
+
56
91
  ```
57
92
 
58
93
  ### 試したこと