fork download
  1. #include <stdio.h>
  2.  
  3. void tarefa(int r) {
  4. for (int e = 1; e <= r; e++) printf(" %d ", r);
  5. printf("\n");
  6. }
  7.  
  8.  
  9. int main(int argc, char *argv[]) {
  10. int x;
  11. scanf("%d", &x);
  12. for (int j = 1; j <= x; j++) tarefa(j);
  13. }
Success #stdin #stdout 0s 9432KB
stdin
5
stdout
 1  
 2   2  
 3   3   3  
 4   4   4   4  
 5   5   5   5   5