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_35030683_5904.cpp:2:21: error: expected ',' or '...' before 'a'
 int dynamicM2(int[] a, int m) {
                     ^
0_0_35030683_5904.cpp: In function 'int dynamicM2(int*)':
0_0_35030683_5904.cpp:4:13: error: 'a' was not declared in this scope
     int n = a.length;
             ^
0_0_35030683_5904.cpp:6:8: error: expected unqualified-id before '[' token
     int[] max = new int[100];
        ^
0_0_35030683_5904.cpp:8:8: error: expected unqualified-id before '[' token
     int[] dp = new int[100];
        ^
0_0_35030683_5904.cpp:10:16: error: 'Integer' was not declared in this scope
     int mMax = Integer.MIN_VALUE;
                ^
0_0_35030683_5904.cpp:12:26: error: 'm' was not declared in this scope
     for (int i = 1; i <= m; i++) {
                          ^
0_0_35030683_5904.cpp:18:13: error: 'dp' was not declared in this scope
             dp[j] = Math.max(dp[j - 1] + a[j], max[j - 1] + a[j]);
             ^
0_0_35030683_5904.cpp:18:21: error: 'Math' was not declared in this scope
             dp[j] = Math.max(dp[j - 1] + a[j], max[j - 1] + a[j]);
                     ^
0_0_35030683_5904.cpp:18:48: error: 'max' was not declared in this scope
             dp[j] = Math.max(dp[j - 1] + a[j], max[j - 1] + a[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-12-02 06:22:48, Gzip enabled