2 like 0 dislike
147 views

設計一個結構儲存個人的資料,包含:姓名(char:10)、出生地(char:10)、出生年(int)與血型。因為出生地與姓名都使用10個字元,所以先以 typedef 定義可以宣告 10 個字元的陣列型別名稱,在結構中就以該名稱來宣告姓名與出生地的成員。而四種不同的血型,必須以 enum 的方式列舉,而血型的型別必須是該列舉型別宣告的部分。在定義結構時,同時宣告結構變數 info,設定姓名為 Frank、出生地台北市、出生年 1995、血型為 O。並在主程式輸出這些個人資料。

 

參考書籍:旗標無痛學習教本

[Normal] Essay (Open question) - asked in Introduction to Computer Programming I (C) by (20.9k points)
ID: 21897 - Available when: Unlimited - Due to: Unlimited
| 147 views
Welcome to Peer-Interaction Programming Learning System (PIPLS) LTLab, National DongHwa University
English 中文 Tiếng Việt
IP:172.70.43.117
©2016-2024

Related questions

2 like 0 dislike
0 answers
[Normal] Essay (Open question) - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21900 - Available when: Unlimited - Due to: Unlimited
| 123 views
2 like 0 dislike
0 answers
[Normal] Essay (Open question) - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21899 - Available when: Unlimited - Due to: Unlimited
| 115 views
1 like 0 dislike
0 answers
[Normal] Essay (Open question) - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21898 - Available when: Unlimited - Due to: Unlimited
| 135 views
2 like 0 dislike
0 answers
[Normal] Essay (Open question) - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21896 - Available when: Unlimited - Due to: Unlimited
| 120 views
3 like 0 dislike
0 answers
[Normal] Essay (Open question) - asked Feb 19, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21943 - Available when: Unlimited - Due to: Unlimited
| 119 views
12,783 questions
183,443 answers
172,219 comments
4,824 users