这九组数据该怎么表示出来呢,感觉好难啊,就是要按照这几组数据的形式,把它输出出来
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
System.out.println("Entry how many rows you want: ");
int howManyRows = input.nextInt();
for (int row = 1; row <= howManyRows+1; row++) {
for (int col = 1; col <= row - 1; col++) {
System.out.print(" ");
}
for (int col = 1; col <= howManyRows-row +1; col++) {
System.out.print(col+" ");
}
System.out.println();
}
}
39行有问题