[問題] while的判斷式裡面有陣列無法跑
開發平台(Platform): (Ex: VC++, GCC, Linux, ...)
VC++
額外使用到的函數庫(Library Used): (Ex: OpenGL, ...)
問題(Question):
while裡面有陣列沒有辦法跑
餵入的資料(Input):
預期的正確結果(Expected Output):
至少能編譯QQ
錯誤結果(Wrong Output):
error C2664: 'int A(double [][2])' : 無法將引數 1 從 'double' 轉換為
'double [][2]'
程式碼(Code):(請善用置底文網頁, 記得排版)
#include <stdio.h>
#include <stdlib.h>
int main(){
double C[2][2] = { 0. };
int A(double B[2][2]);
while (A(C[2][2])){
printf("good!");
}
system("pause");
return 0;
}
int A(double B[2][2]){
return 0;
}
補充說明(Supplement):
上面只是簡單把我程式用到的問題簡化,實際上上面程式沒啥特殊意義...
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 140.113.65.16
※ 文章網址: http://www.ptt.cc/bbs/C_and_CPP/M.1407686458.A.662.html
→
08/11 00:05, , 1F
08/11 00:05, 1F
→
08/11 00:24, , 2F
08/11 00:24, 2F
→
08/11 02:19, , 3F
08/11 02:19, 3F
→
08/11 02:24, , 4F
08/11 02:24, 4F
→
08/11 02:27, , 5F
08/11 02:27, 5F
→
08/11 12:23, , 6F
08/11 12:23, 6F
C_and_CPP 近期熱門文章
PTT數位生活區 即時熱門文章