QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#352105 | #7933. Build Permutation | ZhangYiDe | Compile Error | / | / | C89 | 1.2kb | 2024-03-12 20:56:13 | 2024-03-12 20:56:13 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
Details
answer.code: In function ‘pailie’: answer.code:11:4: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode 11 | for(int i=0;i<n;i++) | ^~~ answer.code:11:4: note: use option ‘-std=c99’, ‘-std=gnu99’, ‘-std=c11’ or ‘-std=gnu11’ to compile your code answer.code:17:4: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode 17 | for (int gap = n / 2; gap > 0; gap /= 2) { | ^~~ answer.code:18:7: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode 18 | for (int i = gap; i < n; i++) { | ^~~ answer.code:31:12: error: redefinition of ‘i’ 31 | for(int i=0;i<n;i++) | ^ answer.code:11:12: note: previous definition of ‘i’ was here 11 | for(int i=0;i<n;i++) | ^ answer.code:31:4: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode 31 | for(int i=0;i<n;i++) | ^~~ answer.code: In function ‘main’: answer.code:44:5: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode 44 | for (int i = 0; i < n; i++) | ^~~ answer.code:54:7: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode 54 | for (int i = 0; i < n; i++) | ^~~ answer.code:42:5: warning: ignoring return value of ‘scanf’, declared with attribute warn_unused_result [-Wunused-result] 42 | scanf("%d",&n); | ^~~~~~~~~~~~~~ answer.code:46:7: warning: ignoring return value of ‘scanf’, declared with attribute warn_unused_result [-Wunused-result] 46 | scanf("%d",&a[i].letter); | ^~~~~~~~~~~~~~~~~~~~~~~~