What will the following script output?

$array = '0123456789ABCDEFG';
  $s = '';
  for ($i = 1; $i < 50; $i++) {
     $s .= $array[rand(0,strlen ($array) - 1)];
  }

echo $s;

  1. A string of 50 random characters

  2. A string of 49 copies of the same character, because the random number generator

  3. A string of 49 random characters

  4. has not been initialized


Correct Option: C

Find more quizzes: