| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 83664 | 胡盛哲 | 图像相似度 | C++ | Compile Error | 0 MS | 0 KB | 429 | 2024-07-14 16:20:06 |
#include <iostream> using namespace std; int a[105][105]; int main() { double n,m; cin>>n>>m; double c=0; int a[n][m],b[n][m]; for(int i=0; i<n; i++) { for(int j=0; j<m; j++) cin>>a[i][j]; } for(int i=0; i<n; i++) { for(int j=0; j<m; j++) cin>>b[i][j]; } for(int i=0; i<n; i++) { for(int j=0; j<m; j++) { if(a[i][j]==b[i][j]) c++; } } printf("%.2lf",c/(n*m)*100.0); return 0; }
Main.cc: In function 'int main()':
Main.cc:8:12: error: size of array 'a' has non-integral type 'double'
int a[n][m],b[n][m];
^
Main.cc:8:12: error: size of array 'a' has non-integral type 'double'
Main.cc:8:20: error: size of array 'b' has non-integral type 'double'
int a[n][m],b[n][m];
^
Main.cc:8:20: error: size of array 'b' has non-integral type 'double'