https://technotes2023.medium.com/recursive-exploration-of-all-possibilities-computer-science-593a2570b46b