[bo][un]卧龙孔明[/un] 在 2008-6-19 19:26 的发言:[/bo]
#include
int main(void)
{
int p=1;
char t[81];
freopen("bslz.in","r",stdin);
freopen("bslz.out","w",stdout);
while(gets(t)!=EOF)
{
if(t[0])
{
...
------ Build started: Project: reshape, Configuration: Debug Win32 ------
Compiling...
reshape.cpp
.\reshape.cpp(6) : warning C4996: 'freopen' was declared deprecated
D:\Program Files\Microsoft Visual Studio 8\VC\include\stdio.h(245) : see declaration of 'freopen'
Message: 'This function or variable may be unsafe. Consider using freopen_s instead. To disable deprecation, use _CRT_SECURE_NO_DEPRECATE. See online help for details.'
.\reshape.cpp(7) : warning C4996: 'freopen' was declared deprecated
D:\Program Files\Microsoft Visual Studio 8\VC\include\stdio.h(245) : see declaration of 'freopen'
Message: 'This function or variable may be unsafe. Consider using freopen_s instead. To disable deprecation, use _CRT_SECURE_NO_DEPRECATE. See online help for details.'
.\reshape.cpp(8) : error C2446: '!=' : no conversion from 'int' to 'char *'
Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
.\reshape.cpp(8) : error C2040: '!=' : 'char *' differs in levels of indirection from 'int'
Build log was saved at "file://c:\Documents and Settings\Chen\My Documents\Visual Studio 2005\Projects\reshape\reshape\Debug\BuildLog.htm"
reshape - 2 error(s), 2 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
这实在Vc++上运行你程序的结果