Challenge: lucky numbers
Lucky numbers are "survivors numbers" in an array once a specific pattern is recursively applied (numbers in array are removed at every recursion cycle). every recursion cycle has to remove numbers from position "p" and every position interval that is the number in starting position. note that in every cycle, p is one bigger than p in previous cycle for example, lucky numbers from 1 to 120 are (1, 3, 7, 9, 13, 15, 21, 25, 31, 33, 37, 43, 49, 51, 63, 67, 69, 73, 75, 79, 87, 93, 99, 105, 111, 115) task: write a code - in every language you prefer - that displays all lucky numbers from 1 to user input p.s.: as explaining this in a few characters is difficult, i post here wikipedia link of the full explanation with examples: https://en.wikipedia.org/wiki/Lucky_number good coding :)