Random Pick With Blacklist

hard
https://leetcode.com/problems/random-pick-with-blacklist/

Input Format

Check the link

Output Format

Check the link

Constraints

Check the link

Notice

Check the link

Example

Input

        
Output

        
Previous
Line Reflection
Next
Longest Substring With At Most Two Distinct Characters

Related Questions