Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <cs50.h>
- #include <stdio.h>
- int
- main (void)
- {
- int height;
- printf ("Enter a number: ");
- scanf ("%d", &height);
- char hash[] = "#";
- int width = 0;
- {
- while (width < height)
- {
- printf (hash);
- printf ("\n");
- width++;
- strcat (hash, "#");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement