java中使用for循環去打印正方形,三角形,菱形等圖形

      1.實心正方形spa    public class 實心正方形 {   public static void main(String[] args) {  int z=5;  for(int i=0;i<z;i++){    for(int j=0;j<z;j++){    System.out.print("*");  }    System.out.println();  } }
相關文章
相關標籤/搜索