| 5 | 1/1 | 返回列表 |
| 查看: 1662 | 回復(fù): 8 | ||
| 當(dāng)前只顯示滿足指定條件的回帖,點擊這里查看本話題的所有回帖 | ||
易沁樺木蟲 (小有名氣)
|
[求助]
VC++下調(diào)試C程序,出現(xiàn)很多語法錯誤
|
|
|
用純的C語言編了個程序(不會C++),在VC++中打開后,點擊Build—Compile后,出現(xiàn)以下:(surface growth.c前面的E:\VC Project\Crystal Growth\都省略了) -----Configuration: surface growth - Win32 Debug-------------------- Compiling... surface growth.c surface growth.c(17) : error C2059: syntax error : '=' surface growth.c(17) : error C2143: syntax error : missing ';' before ')' surface growth.c(19) : warning C4552: '<=' : operator has no effect; expected operator with side-effect surface growth.c(19) : error C2143: syntax error : missing ';' before ')' surface growth.c(23) : error C2059: syntax error : 'for' surface growth.c(23) : error C2143: syntax error : missing '{' before '<=' surface growth.c(23) : error C2059: syntax error : '<=' surface growth.c(23) : error C2143: syntax error : missing '{' before '++' surface growth.c(23) : error C2059: syntax error : '++' surface growth.c(23) : error C2059: syntax error : ')' surface growth.c(24) : error C2143: syntax error : missing '{' before '<=' surface growth.c(24) : error C2059: syntax error : '<=' surface growth.c(24) : error C2143: syntax error : missing '{' before '++' surface growth.c(24) : error C2059: syntax error : '++' surface growth.c(24) : error C2059: syntax error : ')' surface growth.c(26) : error C2059: syntax error : 'for' surface growth.c(26) : error C2143: syntax error : missing '{' before '<=' surface growth.c(26) : error C2059: syntax error : '<=' surface growth.c(26) : error C2143: syntax error : missing '{' before '++' surface growth.c(26) : error C2059: syntax error : '++' surface growth.c(26) : error C2059: syntax error : ')' surface growth.c(27) : error C2143: syntax error : missing '{' before '<=' surface growth.c(27) : error C2059: syntax error : '<=' surface growth.c(27) : error C2143: syntax error : missing '{' before '++' surface growth.c(27) : error C2059: syntax error : '++' surface growth.c(27) : error C2059: syntax error : ')' surface growth.c(36) : error C2059: syntax error : 'for' surface growth.c(36) : error C2143: syntax error : missing '{' before '<=' surface growth.c(36) : error C2059: syntax error : '<=' surface growth.c(36) : error C2143: syntax error : missing '{' before '++' surface growth.c(36) : error C2059: syntax error : '++' surface growth.c(36) : error C2059: syntax error : ')' surface growth.c(45) : error C2059: syntax error : 'for' surface growth.c(45) : error C2143: syntax error : missing '{' before '<' surface growth.c(45) : error C2059: syntax error : '<' surface growth.c(45) : error C2059: syntax error : ')' surface growth.c(46) : error C2449: found '{' at file scope (missing function header?) surface growth.c(149) : error C2059: syntax error : '}' surface growth.c(151) : error C2143: syntax error : missing ')' before 'string' surface growth.c(151) : error C2143: syntax error : missing '{' before 'string' surface growth.c(151) : error C2059: syntax error : ' surface growth.c(151) : error C2059: syntax error : ')' surface growth.c(152) : error C2059: syntax error : 'for' surface growth.c(152) : error C2143: syntax error : missing '{' before '<=' surface growth.c(152) : error C2059: syntax error : '<=' surface growth.c(152) : error C2143: syntax error : missing '{' before '++' surface growth.c(152) : error C2059: syntax error : '++' surface growth.c(152) : error C2059: syntax error : ')' surface growth.c(158) : error C2059: syntax error : '}' 執(zhí)行 cl.exe 時出錯. surface growth.obj - 1 error(s), 0 warning(s) —————————————————————— 可是我覺得語法沒有錯,比如最開始兩句,對應(yīng)第17行的句子是: for (x = 1; x < =N; x++),“=”號怎么有錯呢,)前面也不用加“;”了啊 而且最后一句顯示只有一個錯誤,到底是哪兒呢? 求大俠解答。若解決了問題,還可以追加金幣,謝謝! |

銅蟲 (著名寫手)
至尊木蟲 (著名寫手)
驃騎將軍

木蟲 (小有名氣)

木蟲 (著名寫手)

| 最具人氣熱帖推薦 [查看全部] | 作者 | 回/看 | 最后發(fā)表 | |
|---|---|---|---|---|
|
[考研] 求調(diào)劑 +3 | 蘆lty 2026-03-25 | 4/200 |
|
|---|---|---|---|---|
|
[考研] 316求調(diào)劑 +9 | 梁茜雯 2026-03-19 | 9/450 |
|
|
[考研] 考研調(diào)劑 +6 | 呼呼?~+123456 2026-03-24 | 6/300 |
|
|
[考研] 303求調(diào)劑 +6 | 藍(lán)山月 2026-03-25 | 6/300 |
|
|
[考研] 08工學(xué)調(diào)劑 +13 | 用戶573181 2026-03-20 | 18/900 |
|
|
[考研] 334分 一志愿武理-080500 材料求調(diào)劑 +4 | 李李不服輸 2026-03-25 | 4/200 |
|
|
[考研] 290分調(diào)劑求助 +3 | 吉祥止止陳 2026-03-25 | 3/150 |
|
|
[考研]
|
然11 2026-03-19 | 6/300 |
|
|
[考研] 一志愿 西北大學(xué) ,070300化學(xué)學(xué)碩,總分287,雙非一本,求調(diào)劑。 +4 | 晨昏線與星海 2026-03-20 | 4/200 |
|
|
[考研] 0703化學(xué)求調(diào)劑 +6 | 奶油草莓. 2026-03-22 | 7/350 |
|
|
[考研] 求調(diào)劑 +5 | 林之夕 2026-03-24 | 5/250 |
|
|
[考研] 一志愿河北工業(yè)大學(xué)0817化工278分求調(diào)劑 +7 | jhybd 2026-03-23 | 12/600 |
|
|
[考研] 一志愿山東大學(xué)藥學(xué)學(xué)碩求調(diào)劑 +3 | 開開心心沒煩惱 2026-03-23 | 4/200 |
|
|
[考研] 284求調(diào)劑 +3 | yanzhixue111 2026-03-23 | 6/300 |
|
|
[考研] 333求調(diào)劑 +3 | ALULU4408 2026-03-23 | 3/150 |
|
|
[論文投稿] 急發(fā)核心期刊論文 +3 | 賢達(dá)問津 2026-03-23 | 5/250 |
|
|
[考研] 350求調(diào)劑 +6 | weudhdk 2026-03-19 | 6/300 |
|
|
[考研] 306求調(diào)劑 +5 | 來好運來來來 2026-03-22 | 5/250 |
|
|
[考研] 336求調(diào)劑 +5 | rmc8866 2026-03-21 | 5/250 |
|
|
[考研] 085601調(diào)劑 358分 +3 | zzzzggh 2026-03-20 | 4/200 |
|