3 like 0 dislike
if (y < 0) x = -y; else x = y; 利用 ?: 來實現,可寫成:

 

參考書籍:旗標無痛學習教本
[Normal] Multichoice - asked in Introduction to Computer Programming I (C) by (20.9k points)
Available when: Unlimited - Due to: Unlimited
| 11 views
Get it on Google Play Welcome to Peer-Interaction Programming Learning System (PIPLS) LTLab, National DongHwa University
English 中文 Tiếng Việt
IP:172.68.65.204
©2016-2019

Related questions

3 like 0 dislike
0 answers
[Normal] Multichoice - asked Feb 19, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
Available when: Unlimited - Due to: Unlimited
| 16 views
3 like 0 dislike
0 answers
[Normal] Multichoice - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
Available when: Unlimited - Due to: Unlimited
| 18 views
3 like 0 dislike
0 answers
[Normal] Multichoice - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
Available when: Unlimited - Due to: Unlimited
| 15 views
3 like 0 dislike
0 answers
[Normal] Multichoice - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
Available when: Unlimited - Due to: Unlimited
| 19 views
3 like 0 dislike
0 answers
[Normal] Multichoice - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
Available when: Unlimited - Due to: Unlimited
| 15 views
9,252 questions
85,585 answers
63,644 comments
2,714 users