i was on the site pyschools working through the exercises, but i dont understand why it wont accept the code i input.
Create a function generateNumbers(start, end, step) that takes in three numbers as arguments and returns a list of numbers ranging from start to the end number (inclusive)and skipping numbers based on the step specified in the arguments. Note: The function range(x, y, z) can takes in 3 arguments. For example, range(1, 11, 2) will return a list of numbers [1,3,5,7,9].
>>> generateNumber(2, 10, 2) [2, 4, 6, 8, 10] >>> generateNumber(10, 10, 1)  >>> generateNumber(20, 0, -3) [20, 17, 14, 11, 8, 5, 2]
so i used the code;
def generateNumber(start, end, step): return [i for i in range(start, end+1, step)]
but it says its not right, whats wrong with it?