谭浩强c语言考试试题.docVIP

  • 14
  • 0
  • 约1.93千字
  • 约 3页
  • 2018-05-05 发布于河南
  • 举报
谭浩强c语言考试试题

1、编程输出一行信息:This is a C program. 2、编程求两个整数a,b的和,并输出a+b sum is a,b的和 3、编程,从键盘输入两个小写字母,并将其转换为相应大写字母,并分别用字符型和整数型输出。 4、写出程序的运行结果 main( ) { printf(\101 \x42 C\n); printf(I say:\How are you?\\n); printf(\\C Program\\\n); printf(Turbo \C\); } 5、写出程序的运行结果 main() { printf(“Y\b=\n”); } 6、写出程序的运行结果 #define PRICE 12.5 main() { int num=3; float total; char ch1,ch2=‘D’; total=num*PRICE; ch1=ch2-‘A’+‘a’; printf(“total=%f,ch1=%c\n”,total,ch1); } 7、写出程序的运行结果 main() { float x; int i;

文档评论(0)

1亿VIP精品文档

相关文档