//用for循环打印三角形 10行
for (int i = 0; i < 10; i++) {
for (int j = 10; j >i ; j--) {
System.out.print(" ");
}
for (int j = 0; j <=i ; j++) {
System.out.print("*");
}
for (int j = 0; j < i; j++) {
System.out.print("*");
}
System.out.println();
}