运行VC++,提示出错.懂的人教下我,小弟叩谢拉
我用运行的程序是,很简单,就是求两个数中最大的一个 ,程序本身没有问题.
#include <iostream.h>
vodi main()
{ float a,b;
cout<<"Enter two float number :"<<endl;
cin>>a>>b;
if(a>b)
cout<<"max is :"<<a<<endl;
else
cout<<"max is :"<<b<<endl;
}
运行程序提示的结果提示出错,它的提示是
Compiling...
pp.cpp
e:\program files\microsoft visual studio\myprojects\pp\pp.cpp(3) : error C2146: syntax error : missing ';' before identifier 'main'
e:\program files\microsoft visual studio\myprojects\pp\pp.cpp(3) : error C2501: 'vodi' : missing storage-class or type specifiers
e:\program files\microsoft visual studio\myprojects\pp\pp.cpp(3) : fatal error C1004: unexpected end of file found
执行 cl.exe 时出错.
pp.exe - 1 error(s), 0 warning(s)
大哥大姐帮忙拉,小弟谢谢拉!!!