F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_24732572_22852.c: In function 'main':
0_0_24732572_22852.c:8:21: error: expected expression before '/' token
     scanf("%d",&t); //test cases
                     ^
0_0_24732572_22852.c:13:27: error: 'n' undeclared (first use in this function)
         scanf("%d %d %d",&n,&m,&q);
                           ^
0_0_24732572_22852.c:13:27: note: each undeclared identifier is reported only once for each function it appears in
0_0_24732572_22852.c:13:30: error: 'm' undeclared (first use in this function)
         scanf("%d %d %d",&n,&m,&q);
                              ^
0_0_24732572_22852.c:13:33: error: 'q' undeclared (first use in this function)
         scanf("%d %d %d",&n,&m,&q);
                                 ^
0_0_24732572_22852.c:15:9: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
         for(int i=0;i<n;i++){
         ^
0_0_24732572_22852.c:15:9: note: use option -std=c99, -std=gnu99, -std=c11 or -std=gnu11 to compile your code
0_0_24732572_22852.c:16:13: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
             for(int j=0;j<m;j++)scanf("%d",&mar[i][j]);
             ^
0_0_24732572_22852.c:24:17: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
                 for(int j=0;j<m;j++){
                 ^
0_0_24732572_22852.c:30:25: error: redefinition of 'j'
                 for(int j=0;j<n;j++){
                         ^
0_0_24732572_22852.c:24:25: note: previous definition of 'j' was here
                 for(int j=0;j<m;j++){
                         ^
0_0_24732572_22852.c:30:17: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
                 for(int j=0;j<n;j++){
                 ^
0_0_24732572_22852.c:36:17: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
                 for(int i=0;i<m;i++)mar[x-1][i]+=y;
                 ^
0_0_24732572_22852.c:39:25: error: redefinition of 'i'
                 for(int i=0;i<m;i++)mar[i][x-1]+=y;break;
                         ^
0_0_24732572_22852.c:36:25: note: previous definition of 'i' was here
                 for(int i=0;i<m;i++)mar[x-1][i]+=y;
                         ^
0_0_24732572_22852.c:39:17: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
                 for(int i=0;i<m;i++)mar[i][x-1]+=y;break;
                 ^
0_0_24732572_22852.c:43:17: error: redefinition of 'i'
         for(int i=0;i<n;i++){
                 ^
0_0_24732572_22852.c:15:17: note: previous definition of 'i' was here
         for(int i=0;i<n;i++){
                 ^
0_0_24732572_22852.c:43:9: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
         for(int i=0;i<n;i++){
         ^
0_0_24732572_22852.c:44:13: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
             for(int j=0;j<m;j++)printf("%d ",mar[i][j]);
             ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2025 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2025-04-06 10:30:10, Gzip enabled