Given an array of possible answers, return a random index of the target value.
Sample Input:
["Solution","pick","pick","pick"], [[[1,2,3,3,3]],[3],[3],[1]]
Sample Output:
[null,4,4,0]
Hints
Hint 1
Store indices of each value in a hash map
Hint 2
When picking, randomly select from the indices list
Hint 3
Use reservoir sampling for O(1) space