Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* This is my program of mario - by Casper Hansen */
- #include <stdio.h>
- #include <cs50.h>
- int main(void)
- {
- int h, j, v;
- do
- {
- printf("how height \n");
- printf("Height:");
- h = GetInt();
- }
- while (h<0 || h>23 );
- for (j=h+1; j>=2; j--)
- {
- for (v =2; v<=h+2; v++)
- if (v < j)
- printf(" ");
- else
- printf("#");
- printf("\n");
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement