0_0_36577672_13852.cpp:1:1: error: 'import' does not name a type
import java.util.ArrayList;
^
0_0_36577672_13852.cpp:2:1: error: 'import' does not name a type
import java.util.Arrays;
^
0_0_36577672_13852.cpp:3:1: error: 'import' does not name a type
import java.util.Scanner;
^
0_0_36577672_13852.cpp:4:1: error: 'import' does not name a type
import java.util.Comparator;
^
0_0_36577672_13852.cpp:7:12: error: expected ':' before 'static'
public static void print(Student[] a)
^
0_0_36577672_13852.cpp:7:30: error: 'Student' has not been declared
public static void print(Student[] a)
^
0_0_36577672_13852.cpp:7:40: error: expected ',' or '...' before 'a'
public static void print(Student[] a)
^
0_0_36577672_13852.cpp:15:12: error: expected ':' before 'static'
public static void main(String[] args)
^
0_0_36577672_13852.cpp:15:29: error: 'String' has not been declared
public static void main(String[] args)
^
0_0_36577672_13852.cpp:15:38: error: expected ',' or '...' before 'args'
public static void main(String[] args)
^
0_0_36577672_13852.cpp:40:1: error: expected ';' after class definition
}
^
0_0_36577672_13852.cpp: In static member function 'static void Main::print(int*)':
0_0_36577672_13852.cpp:9:9: error: 'Arrays' was not declared in this scope
Arrays.sort(a,Comparator.comparing(Student::getComTime));//签到时间从小到大排序
^
0_0_36577672_13852.cpp:9:21: error: 'a' was not declared in this scope
Arrays.sort(a,Comparator.comparing(Student::getComTime));//签到时间从小到大排序
^
0_0_36577672_13852.cpp:9:23: error: 'Comparator' was not declared in this scope
Arrays.sort(a,Comparator.comparing(Student::getComTime));//签到时间从小到大排序
^
0_0_36577672_13852.cpp:9:44: error: 'Student' has not been declared
Arrays.sort(a,Comparator.comparing(Student::getComTime));//签到时间从小到大排序
^
0_0_36577672_13852.cpp:10:9: error: 'System' was not declared in this scope
System.out.print(a[0].getId()+" ");
^
0_0_36577672_13852.cpp:12:45: error: 'Student' has not been declared
Arrays.sort(a, Comparator.comparing(Student::getGoTime).reversed());//签离时间从大到小排序
^
0_0_36577672_13852.cpp: In static member function 'static void Main::main(int*)':
0_0_36577672_13852.cpp:17:9: error: 'Scanner' was not declared in this scope
Scanner in=new Scanner(System.in);
^
0_0_36577672_13852.cpp:19:11: error: 'in' was not declared in this scope
n=in.nextInt();
^
0_0_36577672_13852.cpp:24:13: error: 'String' was not declared in this scope
String id;
^
0_0_36577672_13852.cpp:25:20: error: expected ';' before 'comTime'
String comTime;
^
0_0_36577672_13852.cpp:26:20: error: expected ';' before 'goTime'
String goTime;
^
0_0_36577672_13852.cpp:27:13: error: 'Student' was not declared in this scope
Student[] students=new Student[m];
^
0_0_36577672_13852.cpp:27:21: error: expected primary-expression before ']' token
Student[] students=new Student[m];
^
0_0_36577672_13852.cpp:30:17: error: 'id' was not declared in this scope
id=in.next();
^
0_0_36577672_13852.cpp:31:17: error: 'comTime' was not declared in this scope
comTime=in.next();
^
0_0_36577672_13852.cpp:32:17: error: 'goTime' was not declared in this scope
goTime=in.next();
^
0_0_36577672_13852.cpp:33:25: error: expected ';' before 'term'
Student term=new Student(id,comTime,goTime);
^
0_0_36577672_13852.cpp:34:17: error: 'students' was not declared in this scope
students[i]=term;
^
0_0_36577672_13852.cpp:34:29: error: 'term' was not declared in this scope
students[i]=term;
^
0_0_36577672_13852.cpp:36:19: error: 'students' was not declared in this scope
print(students);
^
0_0_36577672_13852.cpp: At global scope:
0_0_36577672_13852.cpp:44:13: error: expected ':' before 'String'
private String id;
^
0_0_36577672_13852.cpp:44:13: error: 'String' does not name a type
0_0_36577672_13852.cpp:45:13: error: expected ':' before 'String'
private String comTime;
^
0_0_36577672_13852.cpp:45:13: error: 'String' does not name a type
0_0_36577672_13852.cpp:46:13: error: expected ':' before 'String'
private String goTime;
^
0_0_36577672_13852.cpp:46:13: error: 'String' does not name a type
0_0_36577672_13852.cpp:48:12: error: expected ':' before 'Student'
public Student(String id,String comTime,String goTime)
^
0_0_36577672_13852.cpp:48:27: error: expected ')' before 'id'
public Student(String id,String comTime,String goTime)
^
0_0_36577672_13852.cpp:55:12: error: expected ':' before 'String'
public String getId()
^
0_0_36577672_13852.cpp:55:12: error: 'String' does not name a type
0_0_36577672_13852.cpp:59:12: error: expected ':' before 'String'
public String getComTime()
^
0_0_36577672_13852.cpp:59:12: error: 'String' does not name a type
0_0_36577672_13852.cpp:64:12: error: expected ':' before 'String'
public String getGoTime()
^
0_0_36577672_13852.cpp:64:12: error: 'String' does not name a type
0_0_36577672_13852.cpp:69:1: error: expected ';' after class definition
}
^
|