📄 halfdollars.java
字号:
class HalfDollars {
public static void main(String[] arguments) {
int[] denver = { 15000006, 18810000, 20752110 };
int[] philadelphia = new int[denver.length];
int[] total = new int[denver.length];
int average;
philadelphia[0] = 15020000;
philadelphia[1] = 18708000;
philadelphia[2] = 21348000;
total[0] = denver[0] + philadelphia[0];
total[1] = denver[1] + philadelphia[1];
total[2] = denver[2] + philadelphia[2];
average = (total[0] + total[1] + total[2]) / 3;
System.out.println("1993 production: " + total[0]);
System.out.println("1994 production: " + total[1]);
System.out.println("1995 production: " + total[2]);
System.out.println("Average production: "+ average);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -