下面这段代码为什么在TC上可以编译,在VC6.0却不能编译?
#include<stdio.h>main(){intf,h;srand((unsigned)time(0));while(!kbhit()){f=rand()%(1-0...
#include<stdio.h>
main()
{
int f,h;
srand((unsigned)time(0));
while(!kbhit()){
f=rand()%(1-0+1)+0;
h=rand()%(1-0+1)+0;
printf("%d,%d\n",f,h);
}
return;
} 展开
main()
{
int f,h;
srand((unsigned)time(0));
while(!kbhit()){
f=rand()%(1-0+1)+0;
h=rand()%(1-0+1)+0;
printf("%d,%d\n",f,h);
}
return;
} 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询