Problem 398 · Medium
Pick a random index with value equal to target. All indices with target value are equally likely.
Open the interactive visualisation