fork download
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3. #include <time.h>
  4.  
  5. int main() {
  6. srand(time(NULL));
  7. const int size = rand() % 10 + 1;
  8. int array[size];
  9.  
  10. for ( int i = 0; i < size; i++ ) {
  11. array[i] = rand() % 100;
  12. printf ("%d ", array[i]);
  13. }
  14.  
  15. return 0;
  16. }
  17.  
Success #stdin #stdout 0s 2248KB
stdin
Standard input is empty
stdout
5 9 24 50