package com.hanqi;
public class sanjiaoxinglingxing {
public static void main(String[] args) {
// TODO 自动生成的方法存根
for (int i = 1; i < 6; i++)
{
for (int j = 1; j <=i; j++)
{
System.out.print("△");
}
System.out.println();
}
System.out.println();
//三角形
//菱形
for (int i = 1; i < 6; i++)
{
for (int j = 1; j<6-i; j++)
{
System.out.print(" ");
}
for (int j = 0; j<2*i-1; j++)
{
System.out.print("◇");
}
System.out.println();
}
for (int i = 1; i < 5; i++)
{
for (int j = 1; j<=i; j++)
{
System.out.print(" ");
}
for (int j = 0; j<2*(5-i)-1; j++)
{
System.out.print("◇");
}
System.out.println();
}
}
}
![](https://images2015.cnblogs.com/blog/917895/201605/917895-20160508205335718-2101530750.png)
![](https://images2015.cnblogs.com/blog/917895/201605/917895-20160508205424187-1311134623.png)