太原理工大学软件java实验报告(8)
发布时间:2021-06-12
发布时间:2021-06-12
}
}
System.out.println("请输入10个数"); double num[] = new double[10];
BufferedReader br = new BufferedReader(new String str;
for (int i = 0; i < 10; i++) { }
for (int j = 1; j < 10; j++) { //冒泡排序 }
System.out.println("顺序为:"); for (int k = 0; k < 10; k++) { }
System.out.print(num[k]+" "); for (int i = 0; i < 10 - j; i++)
if (num[i] > num[i + 1]) { }
t = num[i];
num[i] = num[i + 1]; num[i + 1] = t;
str = br.readLine();
num[i] = Double.parseDouble(str);
InputStreamReader(System.in));
(2) 求一个3*3矩阵对角元素之和。 package com.zhangqian.exercise1;
上一篇:宜春一对一辅导机构哪家好