记录详情

Compile Error

/in/Main.java:18: error: class, interface, or enum expected
public classMain{
       ^
/in/Main.java:19: error: class, interface, or enum expected
    public static void main(String[] args){
                  ^
/in/Main.java:21: error: class, interface, or enum expected
        a=s.nextFloat();
        ^
/in/Main.java:22: error: class, interface, or enum expected
        b=s.nextFloat();
        ^
/in/Main.java:23: error: class, interface, or enum expected
        c=s.nextFloat();
        ^
/in/Main.java:24: error: class, interface, or enum expected
        s.close();
        ^
/in/Main.java:25: error: class, interface, or enum expected
        float p=(a+b+c)/2;
        ^
/in/Main.java:26: error: class, interface, or enum expected
        double S=Math.pow(p*(p-a)*(p-b)*(p-c),(1/2));
        ^
/in/Main.java:27: error: class, interface, or enum expected
        DecimalFormat df=new DecinalFormat("#.00");
        ^
/in/Main.java:28: error: class, interface, or enum expected
        System.out.println(df.format(s));
        ^
/in/Main.java:29: error: class, interface, or enum expected
    }
    ^
11 errors

信息

递交者
类型
递交
题目
三角形面积
语言
Java
递交时间
2024-06-16 07:13:50
评测时间
2024-06-16 07:13:50
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes