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_39283658_20382.cpp:3:5: error: declaration of 'a' as multidimensional array must have bounds for all dimensions except the first
    3 | int a[][]=new int[100000][11];
      |     ^
0_0_39283658_20382.cpp:4:5: error: declaration of 'dp' as multidimensional array must have bounds for all dimensions except the first
    4 | int dp[][]=new int[100000][11];
      |     ^~
0_0_39283658_20382.cpp: In function 'int main()':
0_0_39283658_20382.cpp:16:33: error: 'a' was not declared in this scope
   16 |                                 a[i][j]=0;
      |                                 ^
0_0_39283658_20382.cpp:21:25: error: 'a' was not declared in this scope
   21 |                         a[t][x]++;
      |                         ^
0_0_39283658_20382.cpp:27:33: error: 'dp' was not declared in this scope
   27 |                                 dp[i][j]=0;
      |                                 ^~
0_0_39283658_20382.cpp:31:25: error: 'dp' was not declared in this scope
   31 |                         dp[0][i]=-1;
      |                         ^~
0_0_39283658_20382.cpp:32:17: error: 'dp' was not declared in this scope
   32 |                 dp[0][5]=0;
      |                 ^~
0_0_39283658_20382.cpp:36:79: error: 'a' was not declared in this scope
   36 |                                         dp[i][j]=max(dp[i-1][j],dp[i-1][j+1])+a[i][j];
      |                                                                               ^
0_0_39283658_20382.cpp:39:79: error: 'a' was not declared in this scope
   39 |                                         dp[i][j]=max(dp[i-1][j],dp[i-1][j-1])+a[i][j];
      |                                                                               ^
0_0_39283658_20382.cpp:42:97: error: 'a' was not declared in this scope
   42 |                                         dp[i][j]=max(max(dp[i-1][j],dp[i-1][j-1]),dp[i-1][j+1])+a[i][j];
      |                                                                                                 ^


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-06-26 21:01:15, Gzip enabled