搜索
首页 电脑/网络 程序设计 C/C++

C语言问题

烦请方便请帮我用C语言编一个程序旅游统计管理:1,2,3--3个景点1,按点击人数排序。2,按各景点门票收入排序。(门票价格自定。)3,如果某景点人数达到上限,需给出提示。(上限人数自定)

全部回答

2006-09-18

0 0
实在没有人为我回答,自己收回

2006-09-12

50 0
谁说不需要?! PRINTF和SCANF函数不都得要?

2006-09-09

46 0
上面那个人的程序中第一个include是不要的.

2006-09-08

82 0
    #includefloatprice1,price2,price3;intcount_max;floatsort(floatincome1,floatincome2,floatincome3)main(){intcount1=0,count2=0,count3=0;intntotal;printf("youshoulddecidethemaxofthepeople'snumber,andthepriceofeveryplace。
    \n");printf("so,first,plaseinputthemaxofpeople'snumber");scanf("%d",&count_max);printf("then,pleaseinputthepriceofeveryplace");scanf("%f,%f,%f",&price1,&price2,&price3);printf("1:summerpalace;\n");printf("2:winterpalace;\n");printf("3:horseracetrack;\n");printf("choosetheplaceyouwanttogoto:\n");printf("EnterEOFcharactertoendinput。
    \n");while((ntotal=getchar())!=EOF){switch(ntotal){case1:++count1;break;case2:++count2;break;case3:++count3;break;case'\n':;case'':break; ("Incorrectnumberentered。
    ");printf("Enteranewnumber:\n");break;}printf("\nTotalsofpeoplenumbersforeachsightspots:\n");printf("summerpalace:%d\n",count1);printf("winterpalace:%d\n",count2);printf("horseracetrack:%d\n",count3);}return0;}。
    。

类似问题换一批

热点推荐

热度TOP

相关推荐
加载中...

热点搜索 换一换

电脑/网络
C/C++
硬件
电脑装机
程序设计
互联网
操作系统/系统故障
笔记本电脑
反病毒
百度
软件
程序设计
C/C++
VB
数据库
汇编语言
JAVA相关
VC++
C#/.NET
其他编程语言
C/C++
C/C++
举报
举报原因(必选):
取消确定举报