作者antirazin (今年是日星来台年~真嗨)
看板TransCSI
标题[问题] 高雄大学94年计概
时间Fri Jun 22 14:16:04 2007
1.The first operational eletronic computer is:
(A)ENIAC (B)UNIVACI (C)IBM 650 (D)IBM 360
2.Which of these is not a component of a typical PC?
(A)Printer (B)Hard disk (C)Wand Scanner (d)Keyboard
(B)和(D)肯定不是~
3.见
http://www2.nuk.edu.tw/lib/exam/94/trans2/94cs(2)-trf.pdf
第27题.
我的解答:
#include <stdio.h>
int main(int argc, char *argv[])
{
int n,h,m,s,exit;
printf("Enter a number of seconds: ");
scanf("%d",&n);
h=n/3600;
m=n%3600/60;
s=n%3600%60;
printf("%d seconds are equal to %d hours ,
%d minutes, and %d seconds.\n",n,h,m,s);
/*printf("Press any key to continue\n");*/
/*scanf("%d\n",&exit);*/
system("pause");
return 0;
}
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 125.226.211.121
※ 编辑: antirazin 来自: 125.226.211.121 (06/22 14:46)
1F:推 abien:如果你碰过编译软体就不会这样做了... 06/22 15:20
2F:推 ahongyeh:试看看 system("pause"); 06/22 17:46
3F:→ ahongyeh:忽然发现...你是我的对手.... >"< 06/22 17:48
4F:→ abien:楼上...XD 06/22 17:48
5F:→ abien:"Press any key to continue..."这行不用刻意打出来 会自动 06/22 17:49
6F:→ abien:产生 06/22 17:50
※ 编辑: antirazin 来自: 125.228.84.194 (06/23 10:05)
7F:推 antirazin:我加上去了...可是com过不了...抱歉我写程式很烂>"< 06/23 10:05
8F:推 ahongyeh:主程式不要加参数~~(括号里的东西都拿掉) 06/23 13:21
9F:→ ahongyeh:另外不要宣告exit~~最後也不用回传值(return那行拿掉) 06/23 13:22
10F:→ ahongyeh:最後~~建议你把错误讯息PO出来~~不然不知道哪边有问题~~ 06/23 13:23
11F:推 bilsted:好怀念阿 这是我考的那年XDD 06/24 00:23
12F:推 bilsted:不过这程式我complier 没问题阿XD 06/24 00:29
13F:推 abien:语法没错不代表答案对阿XD 06/24 00:35
14F:推 abien:system("pause") 使用include<stdlib.h> 而且是print出 06/24 00:43
15F:→ abien:"请按任意键继续..." 06/24 00:44
16F:推 antirazin:.....原来是<stdlib.h>和<stdio.h>啊....= = 06/24 09:17
17F:推 antirazin:送阿~~~~成功了XDDDDDDDDD 感谢各位大大相助 06/24 09:22
※ 编辑: antirazin 来自: 125.228.130.124 (06/24 09:24)