4 like 1 dislike
某地的計程車費率計算方式為:前1.25公里的基本費70元,之後每200公尺收費5元。請設計一程式,由使用者輸入里程數,程式會計算相對應的車資輸出。

 

輸入說明:

會輸入一個包含小數點的數,該數不會大於float可儲存的範圍

 

輸出說明:

請輸出一個正整數,代標需要付的車資。

 

輸入範例

2.0

 

輸出範例

85
[Exam] asked in 2017-1 程式設計(一)AD by (30k points)
Available when: Unlimited - Due to: 2017-10-27 21:30

edited by | 47 views

31 Answers

0 like 0 dislike
Hidden content!
** ** * ** ** ** * * * *** *** **
100/100 answered by (215 points)
0 like 0 dislike
Hidden content!
* * ** ** * * ** * ** * * * ** * * *** ** * *
100/100 answered by (190 points)
0 like 0 dislike
Hidden content!
***** * * *** ** * * ***** *** * * ** **** *
100/100 answered by (194 points)
0 like 0 dislike
Hidden content!
* * * *** ** *



int * * **



{
* * *   float x;
** **   * ** * ** input your ** * ****
**   * *** ** ** ***** *
** *** **   int y;
** *   ** *** *
*** * * * ** *** ** * ** ** * ***
* * * ** *** * *** * ** ** **
* * *** ** * * * * int z;
* ******* * * *** *

  * ** ** **** **
*** * * ** * * ** **** *** *** * ******

}
*
100/100 answered by (162 points)
0 like 0 dislike
Hidden content!
* ** ** * * * * * * * * ** * *** * * *** ***
100/100 answered by (172 points)
0 like 0 dislike
Hidden content!
* *** ******** * * ** *** * *** **
100/100 answered by (224 points)
0 like 0 dislike
Hidden content!
*** * ****** *** * ** ** * * *** * ***
100/100 answered by (154 points)
0 like 0 dislike
Hidden content!
* *** * * * * * ** * * * *** * ** ***
100/100 answered by (162 points)
0 like 0 dislike
Hidden content!
* * * **** ** * * * ***** * ** * * * *
100/100 answered by (100 points)
0 like 0 dislike
Hidden content!
* * * ***** ** * ** * * *** **** *******
100/100 answered by (106 points)
Get it on Google Play Welcome to Peer-Interaction Programming Learning System (PIPLS) LTLab, National DongHwa University
English 中文 Tiếng Việt
IP:162.158.79.167
©2016-2019

Related questions

3 like 0 dislike
12 answers
[Exam] asked Dec 23, 2017 in 2017-1 程式設計(一)AD by 楊修俊 (30k points)
Available when: 2017-12-23 09:00 - Due to: 2017-12-23 12:10
| 92 views
2 like 0 dislike
0 answers
[Resource] asked Nov 9, 2017 in 2017-1 程式設計(一)AD by 楊修俊 (30k points)
Available when: Unlimited - Due to: Unlimited
| 17 views
2 like 0 dislike
0 answers
[Resource] asked Nov 9, 2017 in 2017-1 程式設計(一)AD by 楊修俊 (30k points)
Available when: Unlimited - Due to: Unlimited
| 14 views
2 like 0 dislike
0 answers
[Resource] asked Nov 9, 2017 in 2017-1 程式設計(一)AD by 楊修俊 (30k points)
Available when: Unlimited - Due to: Unlimited
| 17 views
9,132 questions
80,613 answers
55,967 comments
2,582 users