首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > C语言 >

这道题不仅让小弟我蛋疼。还让小弟我有挥刀自宫的冲动

2012-04-23 
这道题不仅让我蛋疼。还让我有挥刀自宫的冲动。编写一个程序。发出警声。并打印下列文字Startled by the sudde

这道题不仅让我蛋疼。还让我有挥刀自宫的冲动。
编写一个程序。发出警声。并打印下列文字
Startled by the sudden sound,Sally shouted,"By the Great Pumpkin,what was that!"

然后我就这样写
#include <stdio.h>
int main()
{
 printf("\aStartled by the sudden sound,");  
 printf("Sally shouted,"By the Great Pumpkin,what was that!"\n");  
 system("pause");  
   
}

结果老是提示那个引号有问题。这题应该很简单才对啊。我怎么可能做不出来。


[解决办法]
双引号里有双引号,里面的双引号必须\"
[解决办法]
printf("Sally shouted,\"By the Great Pumpkin,what was that!\"\n"); //要用转义

热点排行