please help me! thanks!
package zh.codegym.task.task05.task0507;
/*
算术平均值
*/
import java.io.*;
public class Solution {
public static void main(String[] args) throws Exception {
//在此编写你的代码
Scanner scanner = null;
int sum=0,num=0,score;
while(true){
scanner = new Scanner(System.in);
score = scanner.nextInt();
if(score == -1){
System.out.println(sum/(float)num);
break;
}else{sum += score;
num++;
continue;
}
}
}
}