package Third;
public class Demo1 {
/**
* 9*9乘法表
* @author zll
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
System.out.println(" Multiplication Table");
System.out.print(" ");
for(int j = 1; j <= 9; j++)
System.out.print(" "+ j);
System.out.println("\n---------------------------------------------------------------------");
for(int i = 1; i <= 9; i++){
System.out.print(i + "|" );
for(int j = 1; j <= 9; j++){
System.out.printf("%4d", i * j);
}
System.out.println();
}
}
}
* 9*9乘法表
最新推荐文章于 2022-06-24 20:27:38 发布