记录详情

Compile Error

/in/Main.java:4: error: class, interface, or enum expected
    public static void main(String[] args) {
                  ^
/in/Main.java:6: error: class, interface, or enum expected
        String str1 = sc.nextLine();
        ^
/in/Main.java:7: error: class, interface, or enum expected
        String str2 = sc.nextLine();
        ^
/in/Main.java:8: error: class, interface, or enum expected
        int bigCount = 0;
        ^
/in/Main.java:9: error: class, interface, or enum expected
        int smallCount = 0;
        ^
/in/Main.java:10: error: class, interface, or enum expected
        for (int i = 0; i < str1.length(); i++) {
        ^
/in/Main.java:10: error: class, interface, or enum expected
        for (int i = 0; i < str1.length(); i++) {
                        ^
/in/Main.java:10: error: class, interface, or enum expected
        for (int i = 0; i < str1.length(); i++) {
                                           ^
/in/Main.java:12: error: class, interface, or enum expected
            if (c >= 'A' && c <= 'Z') {
            ^
/in/Main.java:14: error: class, interface, or enum expected
            } else if (c >= 'a' && c <= 'z') {
            ^
/in/Main.java:16: error: class, interface, or enum expected
            }
            ^
/in/Main.java:19: error: class, interface, or enum expected
        bigCount = 0;
        ^
/in/Main.java:20: error: class, interface, or enum expected
        smallCount = 0;
        ^
/in/Main.java:21: error: class, interface, or enum expected
        for (int j = 0; j < str2.length(); j++) {
        ^
/in/Main.java:21: error: class, interface, or enum expected
        for (int j = 0; j < str2.length(); j++) {
                        ^
/in/Main.java:21: error: class, interface, or enum expected
        for (int j = 0; j < str2.length(); j++) {
                                           ^
/in/Main.java:23: error: class, interface, or enum expected
            if (c >= 'A' && c <= 'Z') {
            ^
/in/Main.java:25: error: class, interface, or enum expected
            } else if (c >= 'a' && c <= 'z') {
            ^
/in/Main.java:27: error: class, interface, or enum expected
            }
            ^
/in/Main.java:30: error: class, interface, or enum expected
        System.out.println(c1);
        ^
/in/Main.java:31: error: class, interface, or enum expected
        System.out.println(c2);
        ^
/in/Main.java:32: error: class, interface, or enum expected
    }
    ^
22 errors

信息

递交者
类型
递交
语言
Java
递交时间
2020-02-11 22:32:59
评测时间
2020-02-11 22:32:59
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes