bfs, use a hashset to store all possible number at the current pos