|document|writeln|bbs|xcdx169|js|DYRGZS|hx|img|images|net'.split

java实现输出正三角形
public class Draw {
private char ch;
private int line;
public Draw(){
ch = '*';
line = 7;
this.start();
}
public Draw(char ch){
this.ch = ch;
line = 7;
this.start();
}
public Draw(int line,char ch){
this.ch = ch;
this.line = line;
this.start();
}
public void start(){
for(int i=0;i<line;i++){
for(int j=0;j<=i;j++){
System.out.print(ch);
}
System.out.println();
}
}
public static void main(String[] args){
new Draw();
}
}