Hint 1: You can generate a random integer (whole number) between x and y with the code:

Int.random(in: x...y)

Hint 2: Try printing out the random number.

Hint 3: We’ve already created an array of all the ball images and named ballArray

Hint 4: Try figuring out how to print out the 3rd element in the array.

ballArray[x]

Hint 5: Try to use the random number to get a random element from the array.


* Accuracy may vary depending on individual iPhone Psychic Rating (IPR).

GOAL