1 like 0 dislike
7.2k views

Write the C program that receives the number of coffee cups and teacups. The program shows the TOTAL price after user press Enter. The price for one cup of coffee is $35, one cup of tea is $25 

寫一個計算咖啡跟茶的總計

Example input:

3 2

Example output:

155
[Exercise] Coding (C) - asked in Chapter 2: C Fundamentals by (9.9k points)
ID: 25482 - Available when: Unlimited - Due to: Unlimited

edited by | 7.2k views

73 Answers

0 like 0 dislike
Hidden content!
*** ** **** *

#define *** * 35

#define * ** 25



int * *

{
** * **** ** ******* a,b,TOTAL;
** * * * * * ********* * ** * ** * ** the number of cup of coffee and cup of **** * * *
* ** *** * ** * ***** * * * ** *** * * * *
* * ** *********** ** * * * ** * ** * * * * * * ** *
* * * *** ** * * ** 0;

}
answered by (-498 points)
0 like 0 dislike
Hidden content!
* ** ***



int main() {
* * *** ** * * *** * * cof,tea;
*** ** ** *** ******* ** ** *** * * ** *** * &cof, ** ** * **
**** ** * * ** ** ** * ** *

}
answered by (-120 points)
0 like 0 dislike
Hidden content!
#include * * * **

#include * * **** * ** *



#define ***** 35

#define TEA_VALUE 25

int *** * ** * * * * *



int main()

{
* * * * * * * ** *** * *** * * * * ** * * * ** **** * * ****


** ** * * * ** ***** * * * = ** ** * * ** ** * + * ** * * ***


** * ** ** ** * * * *** *** * * ** * * * * **
* ** * *** * ** * * ** 0;

}
answered by (-286 points)
Welcome to Peer-Interaction Programming Learning System (PIPLS) LTLab, National DongHwa University
English 中文 Tiếng Việt
IP:172.69.17.93
©2016-2025

Related questions

4 like 1 dislike
61 answers
[Exercise] Coding (C) - asked Sep 28, 2017 in Chapter 2: C Fundamentals by thopd (12.1k points)
ID: 25484 - Available when: Unlimited - Due to: Unlimited
| 6.3k views
2 like 0 dislike
50 answers
[Exercise] Coding (C) - asked Sep 28, 2017 in Chapter 2: C Fundamentals by thopd (12.1k points)
ID: 25483 - Available when: Unlimited - Due to: Unlimited
| 5.6k views
12,783 questions
183,442 answers
172,219 comments
4,824 users