*.*.
*..*..*..
*...*...*...*...
*....*....*....*....*....
*.....*.....*.....*.....*.....*.....
*......*......*......*......*......*......*......
*.......*.......*.......*.......*.......*.......*.......*.......
public class PrintStar {
public static void main(String[] args) {
// TODO, add your application code
for(int row=0;row<7;row++){ //输出数字
for(int star=0;star<=row+1;star++){
System.out.print("*");
for(int space=0;space<=row;space++){ //输出空格
System.out.print(".");
}
}
System.out.println();
}
}
}