FunctionRacerProblemsRace

Multiples Up To

BeginnerNumPyPython

Return a list of all the multiples of k from k up to n (including n if it is a multiple), smallest first. If k is bigger than n, return an empty list. Hint: np.arange takes a start, a stop and a step.

Example 1

k 3
n 10
returns [3,6,9]

3, 6 and 9 are the multiples of 3 up to 10.

Constraints

Race itor take your time

Write it in your browser, against the clock. The model solution, stepped through line by line, comes after.

More NumPy problems