第一章课的时候,检测的出现了错误,不明白
本帖最后由 zxsa 于 2016-11-16 13:27 编辑#include {stdio.h}
void main()
{
printf("世界,您好! \n");
}
检测的出现了错误,不明白
Compiling...
Hello world 3.c
d:\vc6.sp6\microsoft visual studio\myprojects\hello world 3\hello world 3.c(1) : error C2006: #include expected a filename, found '{'
d:\vc6.sp6\microsoft visual studio\myprojects\hello world 3\hello world 3.c(5) : warning C4013: 'printf' undefined; assuming extern returning int
Error executing cl.exe.
#include {stdio.h}
#include {math.h}
void main()
{
double x, s;
printf("input number:\n");
scanf("%1f", &x);
s = sin(x);
printf("sin of %1f is %1f\n", x, s);
}
Compiling...
Hello world.c
d:\vc6.sp6\microsoft visual studio\myprojects\hello world\hello world.c(1) : error C2006: #include expected a filename, found '{'
d:\vc6.sp6\microsoft visual studio\myprojects\hello world\hello world.c(2) : error C2006: #include expected a filename, found '{'
d:\vc6.sp6\microsoft visual studio\myprojects\hello world\hello world.c(8) : warning C4013: 'printf' undefined; assuming extern returning int
d:\vc6.sp6\microsoft visual studio\myprojects\hello world\hello world.c(9) : warning C4013: 'scanf' undefined; assuming extern returning int
d:\vc6.sp6\microsoft visual studio\myprojects\hello world\hello world.c(10) : warning C4013: 'sin' undefined; assuming extern returning int
Error executing cl.exe. 头文件括号打错了〈〉 自己动点脑,这么简单问题自己解决不了,你很难坚持下去 hb328496536 发表于 2016-11-16 11:58
自己动点脑,这么简单问题自己解决不了,你很难坚持下去
刚刚开始学,还不知道哪个符号是哪个,不好意思,占用你的时间了,谢谢你提供的帮助! ...
其实我脾气确实还需要修炼哎……
页:
[1]