required: double [] found: no arguments

前端 未结 4 896
自闭症患者
自闭症患者 2021-01-14 20:38

Code:

 ArrayList  marks = new ArrayList();

 String output = \"Class average:\" + calculateAverage() + \"\\n\" + \"Maximum mark:\" +  
 calcu         


        
4条回答
  •  生来不讨喜
    2021-01-14 21:00

    You can call it this way:

    double d[] = {1, 2, 3};
    double ret = calculateAverage(d);
    System.out.println(ret);
    

提交回复
热议问题