| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 1476 人关注过本帖
标题:C程序编译出错,为何找不出错误
只看楼主 加入收藏
断浪留丹
Rank: 1
等 级:新手上路
帖 子:5
专家分:0
注 册:2006-12-11
收藏
 问题点数:0 回复次数:5 
C程序编译出错,为何找不出错误

0.c
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(20) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(20) : warning C4550: expression evaluates to a function which is missing an argument list
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(21) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(21) : warning C4550: expression evaluates to a function which is missing an argument list
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(22) : error C2065: 'Display' : undeclared identifier
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(22) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(25) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(40) : error C2236: unexpected 'struct' 'StudentScore'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2017: illegal escape sequence
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2018: unknown character '0xca'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2018: unknown character '0xe4'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2018: unknown character '0xc8'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2018: unknown character '0xeb'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2018: unknown character '0xb3'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2018: unknown character '0xc9'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2018: unknown character '0xbc'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2018: unknown character '0xa8'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2065: 'n' : undeclared identifier
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : warning C4047: 'function' : 'const char *' differs in levels of indirection from 'int '
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : warning C4024: 'printf' : different types for formal and actual parameter 1
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2143: syntax error : missing ')' before ':'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(46) : error C2059: syntax error : ')'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(47) : warning C4133: 'function' : incompatible types - from 'float [30]' to 'char *'
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(58) : error C2065: 'score' : undeclared identifier
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(58) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(58) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(58) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(58) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(61) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(61) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(69) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(69) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(71) : warning C4244: 'return' : conversion from 'int ' to 'float ', possible loss of data
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(79) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(79) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(81) : warning C4244: 'return' : conversion from 'int ' to 'float ', possible loss of data
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(87) : error C2065: 'averageStu' : undeclared identifier
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(87) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(87) : warning C4244: '=' : conversion from 'float ' to 'int ', possible loss of data
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(87) : error C2106: '=' : left operand must be l-value
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(89) : error C2065: 'averageCourse' : undeclared identifier
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(89) : error C2109: subscript requires array or pointer type
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(89) : warning C4244: '=' : conversion from 'float ' to 'int ', possible loss of data
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(89) : error C2106: '=' : left operand must be l-value
C:\Program Files\Microsoft Visual Studio\MyProjects\0\0.c(100) : error C2236: unexpected 'struct' 'StudentScore'
执行 cl.exe 时出错.

0.obj - 1 error(s), 0 warning(s)
麻烦各位高手忙我看一下这究竟是什么问题啊!

搜索更多相关主题的帖子: 编译 
2006-12-11 11:12
卧龙孔明
Rank: 9Rank: 9Rank: 9
等 级:贵宾
威 望:59
帖 子:3872
专家分:684
注 册:2006-10-13
收藏
得分:0 
把源程序帖出来

My Blog: www.aiexp.info
虽然我的路是从这里开始的,但是这里不再是乐土.感谢曾经影响过,引导过,帮助过我的董凯,飞燕,leeco,starwing,Rockcarry,soft_wind等等等等.别了,BCCN.
2006-12-11 12:24
秋阁
Rank: 1
等 级:新手上路
帖 子:31
专家分:0
注 册:2006-7-15
收藏
得分:0 
换个编译软件试试
2006-12-11 13:06
lefttime
Rank: 1
等 级:新手上路
帖 子:162
专家分:0
注 册:2006-10-6
收藏
得分:0 

最好把你的源程序贴出来


我是金子,我要闪光的
2006-12-11 19:34
卧龙孔明
Rank: 9Rank: 9Rank: 9
等 级:贵宾
威 望:59
帖 子:3872
专家分:684
注 册:2006-10-13
收藏
得分:0 
以下是引用秋阁在2006-12-11 13:06:32的发言:
换个编译软件试试

同意,建议用TC,GCC试试


My Blog: www.aiexp.info
虽然我的路是从这里开始的,但是这里不再是乐土.感谢曾经影响过,引导过,帮助过我的董凯,飞燕,leeco,starwing,Rockcarry,soft_wind等等等等.别了,BCCN.
2006-12-11 20:18
走刀口→超
Rank: 6Rank: 6
等 级:贵宾
威 望:20
帖 子:5018
专家分:0
注 册:2006-3-14
收藏
得分:0 
LZ用的MS是C++这个就麻烦咯。。。

人在江湖【走】,怎能不挨【刀】;为了能活【口】,唯有把己【超】!come on...
2006-12-11 20:19
快速回复:C程序编译出错,为何找不出错误
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.047893 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved