public class K8 {
public static void main(String[] args) {
int [] nums = {1,2,3,2,5,3,7,3,8,2,4,9,3,2,6,4};
int count=0;
for (int i = 1; i < 10; i++) {
for (int j = 0; j < nums.length; j++) {
if(nums[j]==i){
count++;
}
}System.out.println(count);
count=0; //这个是什么意思。谢谢
}
}
} |