Advertisement
rdsedmundo

col_prin.c

May 9th, 2013
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.27 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5.     char n[128];
  6.     printf("Digite uma palavra: ");
  7.     gets(n);
  8.  
  9.     for(int i = 0; i <= strlen(n); i++) {
  10.         for(int k = i; k > 0; k--) {
  11.             printf("%s ", n);
  12.         }
  13.         printf("\n");
  14.     }
  15.     return 0;
  16. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement