2015/12/29 eclipse应用 输出三角形
1 public class Myfirst { 2 3 4 public static void main(String[] args) { 5 System.out.println("hello world"); 6 System.out.println(""); 7 System.out.println("□□□□□□□"); 8 System.out.println("■■■□■■■"); 9 System.out.println("■■■□■■■"); 10 System.out.println("□□□□□□□"); 11 System.out.println("■■■□■■■"); 12 System.out.println("■■■□■■■"); 13 System.out.println("□□□□□□□"); 14 System.out.println(""); 15 System.out.println("▼▲▼▲▼"); 16 System.out.println(" ▼▲▼▼"); 17 System.out.println(" ▼▲▼"); 18 System.out.println(" ▼▼"); 19 System.out.println(" ▼"); 20 21 22 } 23 }