fork(1) download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. char i, j;
  5. char input, alphabet = 'A';
  6.  
  7. printf("Enter the uppercase character you want to print in last row: ");
  8. scanf("%c",&input);
  9.  
  10. for(i='A'; i <= input; ++i)
  11. {
  12. for(j='A';j<=i;++j)
  13. {
  14. printf("%c", input);
  15. }
  16.  
  17.  
  18. printf("\n");
  19. }
  20. return 0;
  21. }
  22.  
Success #stdin #stdout 0s 9432KB
stdin
C
stdout
Enter the uppercase character you want to print in last row: C
CC
CCC