package com.javase.demo;
import java.util.Scanner;
/**
* 金字塔
* @author Mr.Zhang
*
*/
public class Pyramid {
static Scanner input = new Scanner(System.in);
/**
* *****打印金字塔*****
* 1,确定金字塔行数
* 2,确认空格数
* 3,确认星星数
* @param args
*/
public static void main(String[] args) {
entrance();
}
/**
* 入口项
*/
public static void entrance() {
System.out.println("请选择(0--正金字塔,1--倒金字塔,2--菱形金字塔)");
String select = input.nextLine();
if(isNumber(select)){
int selectInt = Integer.parseInt(select);
switch(selectInt){
case 0:
uprightPyramid();
break;
case 1:
fallPyramid();
break;