注册 登录
编程论坛 C图形专区

[新手求助]错误一个

火乍弓单 发布于 2008-01-08 17:36, 1128 次点击
我刚学C,这段代码是在TC++3.0下编译的,大家帮我看看有什么错误
#include"graphics.h"
void main(void)
{
    int driver,mode;
    driver=DETECT;
    mode=0;
    initgraph(&driver,&mode,"");
    circle(200,200,20);
    circle(200,200,30);
    circle(200,200,40);
    getch();
    restorecrtmode();
}
错误信息是
Error NONAME.C 11:Function 'getch' should have a prototype
谢谢了
3 回复
#2
jig2008-01-08 18:17
去再试试

看少了什么头文件不?这个还是要自己多摸索摸索~~
#3
yrj0072008-01-08 21:02
win TC 能通过
#4
火乍弓单2008-01-08 21:13
谢谢,我在win-tc下运行可以了
1