Guest User

Untitled

a guest
Mar 19th, 2018
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3.  
  4. int main()
  5. {
  6. //Dichiaro le costanti
  7. int x,i,k;
  8. char c='*';
  9.  
  10. //Prelevo i dati
  11. printf("Inserire un numero: \n");
  12. scanf("%d", &x);
  13.  
  14. //Stampo il risultato
  15. for(i=0;i<x;i++){
  16. printf("\n");
  17. for(k=0;k<=i;k++){
  18. printf("%c", c);
  19. }
  20. }
  21. return 0;
  22. }
Add Comment
Please, Sign In to add comment