0_0_38593779_26624.cpp:1:1: error: 'import' does not name a type; did you mean 'short'?
import java.util.*;
^~~~~~
short
0_0_38593779_26624.cpp:4:25: error: 'List' has not been declared
static int MinScore(List<Integer> cards) {
^~~~
0_0_38593779_26624.cpp:4:29: error: expected ',' or '...' before '<' token
static int MinScore(List<Integer> cards) {
^
0_0_38593779_26624.cpp:30:34: error: multidimensional array must have bounds for all dimensions except the first
static void PrintParen(int[][] s, int i, int j) {
^
0_0_38593779_26624.cpp:30:36: error: expected ',' or '...' before 's'
static void PrintParen(int[][] s, int i, int j) {
^
0_0_38593779_26624.cpp:42:11: error: expected ':' before 'static'
public static void main(String[] args) {
^~~~~~~
:
0_0_38593779_26624.cpp:42:29: error: 'String' has not been declared
public static void main(String[] args) {
^~~~~~
0_0_38593779_26624.cpp:42:38: error: expected ',' or '...' before 'args'
public static void main(String[] args) {
^~~~
0_0_38593779_26624.cpp:58:2: error: expected ';' after class definition
}
^
;
0_0_38593779_26624.cpp: In static member function 'static int Main::MinScore(int)':
0_0_38593779_26624.cpp:5:17: error: 'cards' was not declared in this scope
int n = cards.size();
^~~~~
0_0_38593779_26624.cpp:6:12: error: structured binding declaration cannot have type 'int'
int[][] d = new int[n][n];
^~
0_0_38593779_26624.cpp:6:12: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
0_0_38593779_26624.cpp:6:12: error: empty structured binding declaration
0_0_38593779_26624.cpp:6:14: error: expected initializer before '[' token
int[][] d = new int[n][n];
^
0_0_38593779_26624.cpp:7:12: error: structured binding declaration cannot have type 'int'
int[][] s = new int[n][n];
^~
0_0_38593779_26624.cpp:7:12: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
0_0_38593779_26624.cpp:7:12: error: empty structured binding declaration
0_0_38593779_26624.cpp:7:14: error: expected initializer before '[' token
int[][] s = new int[n][n];
^
0_0_38593779_26624.cpp:12:17: error: 'd' was not declared in this scope
d[i][j] = Integer.MAX_VALUE;
^
0_0_38593779_26624.cpp:12:27: error: 'Integer' was not declared in this scope
d[i][j] = Integer.MAX_VALUE;
^~~~~~~
0_0_38593779_26624.cpp:17:25: error: 's' was not declared in this scope
s[i][j] = k;
^
0_0_38593779_26624.cpp:23:9: error: 'System' was not declared in this scope
System.out.print("The optimal parenthesization is: ");
^~~~~~
0_0_38593779_26624.cpp:24:20: error: 's' was not declared in this scope
PrintParen(s, 1, n - 1);
^
0_0_38593779_26624.cpp:27:16: error: 'd' was not declared in this scope
return d[1][n - 1];
^
0_0_38593779_26624.cpp: In static member function 'static void Main::PrintParen()':
0_0_38593779_26624.cpp:31:13: error: 'i' was not declared in this scope
if (i == j) {
^
0_0_38593779_26624.cpp:31:18: error: 'j' was not declared in this scope
if (i == j) {
^
0_0_38593779_26624.cpp:32:13: error: 'System' was not declared in this scope
System.out.print("A" + i);
^~~~~~
0_0_38593779_26624.cpp:36:9: error: 'System' was not declared in this scope
System.out.print("(");
^~~~~~
0_0_38593779_26624.cpp:37:20: error: 's' was not declared in this scope
PrintParen(s, i, s[i][j]);
^
0_0_38593779_26624.cpp:37:23: error: 'i' was not declared in this scope
PrintParen(s, i, s[i][j]);
^
0_0_38593779_26624.cpp:37:31: error: 'j' was not declared in this scope
PrintParen(s, i, s[i][j]);
^
0_0_38593779_26624.cpp: In static member function 'static void Main::main(int*)':
0_0_38593779_26624.cpp:43:9: error: 'Scanner' was not declared in this scope
Scanner scanner = new Scanner(System.in);
^~~~~~~
0_0_38593779_26624.cpp:45:16: error: 'scanner' was not declared in this scope
while (scanner.hasNextInt()) {
^~~~~~~
0_0_38593779_26624.cpp:47:13: error: 'List' was not declared in this scope
List<Integer> cards = new ArrayList<>();
^~~~
0_0_38593779_26624.cpp:47:13: note: suggested alternative: 'int'
List<Integer> cards = new ArrayList<>();
^~~~
int
0_0_38593779_26624.cpp:47:18: error: 'Integer' was not declared in this scope
List<Integer> cards = new ArrayList<>();
^~~~~~~
0_0_38593779_26624.cpp:47:27: error: 'cards' was not declared in this scope
List<Integer> cards = new ArrayList<>();
^~~~~
0_0_38593779_26624.cpp:47:27: note: suggested alternative: 'ncards'
List<Integer> cards = new ArrayList<>();
^~~~~
ncards
0_0_38593779_26624.cpp:47:39: error: 'ArrayList' does not name a type
List<Integer> cards = new ArrayList<>();
^~~~~~~~~
0_0_38593779_26624.cpp:47:49: error: expected primary-expression before '>' token
List<Integer> cards = new ArrayList<>();
^
0_0_38593779_26624.cpp:47:51: error: expected primary-expression before ')' token
List<Integer> cards = new ArrayList<>();
^
0_0_38593779_26624.cpp:53:13: error: 'System' was not declared in this scope
System.out.println("The minimum cost is: " + MinScore(cards));
^~~~~~
0_0_38593779_26624.cpp:56:9: error: 'scanner' was not declared in this scope
scanner.close();
^~~~~~~
|