Skip to content

Latest commit

 

History

History

less

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Implements a program that prints out a half-pyramid of a specified height, per the below.

$ ./mario
Height: 5
    ##
   ###
  ####
 #####
######
$ ./mario
Height: 3
  ##
 ###
####

Usage

Program should behave per the example below. Assumed that the underlined text is what some user has typed.

$ ./mario
Height: 4
   ##
  ###
 ####
#####
$ ./mario
Height: 0
$ ./mario
Height: -5
Height: 4
   ##
  ###
 ####
#####
$ ./mario
Height: -5
Height: five
Height: 40
Height: 24
Height: 4
   ##
  ###
 ####
#####