import java.io.IOException;
public class Rhombus {
private static String c;
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
System.out.print("请输入五位以内的一个数字:");
byte[] temp = new byte[5];
try {
System.in.read(temp);
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
c = new String(temp).trim();
if (!c.equals("")){
draw();
}
}
public static void draw(){
int n = Integer.parseInt(c);
boolean isAdd = true;
int count = 1;
for (int i = 1; i <= n; i++){
print(n, count);
System.out.print('/n');
if (count >= n){
isAdd = false;
}
if (isAdd){
count = count + 2;
}else{
count = count - 2;
}
}
}
public static void print(int n, int count){
int fistSpace = 0;
fistSpace = (n - count) / 2;
for (int i = 0; i < fistSpace; i++){
System.out.print(" ");
}
for (int j = 0; j < count; j++){
System.out.print("* ");
}
}
}