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_39673951_25656.cpp:4:13: error: expected unqualified-id before '[' token
    4 | int sum[26];[10001];
      |             ^
0_0_39673951_25656.cpp: In function 'int main()':
0_0_39673951_25656.cpp:10:31: error: 'n' was not declared in this scope
   10 |                 scanf("%d%d",&n,&q);
      |                               ^
0_0_39673951_25656.cpp:10:34: error: 'q' was not declared in this scope
   10 |                 scanf("%d%d",&n,&q);
      |                                  ^
0_0_39673951_25656.cpp:13:52: error: invalid types 'int[int]' for array subscript
   13 |                         for(int j=0;j<26;j++)sum[j][i]=sum[j][i-1];
      |                                                    ^
0_0_39673951_25656.cpp:13:62: error: invalid types 'int[int]' for array subscript
   13 |                         for(int j=0;j<26;j++)sum[j][i]=sum[j][i-1];
      |                                                              ^
0_0_39673951_25656.cpp:14:40: error: invalid types 'int[int]' for array subscript
   14 |                         sum[str[i]-'A'][i]++;
      |                                        ^
0_0_39673951_25656.cpp:20:42: error: invalid types 'int[int]' for array subscript
   20 |                                 if(sum[i][r]-sum[i][l-1]!=0){
      |                                          ^
0_0_39673951_25656.cpp:20:52: error: invalid types 'int[int]' for array subscript
   20 |                                 if(sum[i][r]-sum[i][l-1]!=0){
      |                                                    ^
0_0_39673951_25656.cpp:21:50: error: invalid types 'int[int]' for array subscript
   21 |                                         if(sum[i][r]-sum[i][l-1]!=0){
      |                                                  ^
0_0_39673951_25656.cpp:21:60: error: invalid types 'int[int]' for array subscript
   21 |                                         if(sum[i][r]-sum[i][l-1]!=0){
      |                                                            ^
0_0_39673951_25656.cpp:22:69: error: invalid types 'int[int]' for array subscript
   22 |                                                 printf("%d\n",sum[i][r]-sum[i][l-1]);
      |                                                                     ^
0_0_39673951_25656.cpp:22:79: error: invalid types 'int[int]' for array subscript
   22 |                                                 printf("%d\n",sum[i][r]-sum[i][l-1]);
      |                                                                               ^


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