With a given integer number n, write a function to get all even numbers starting from 1.
- Define function 'get_even_numbers' which will accept number argument.
- Number should not be less than 0.
- Function should pass all test cases.
Instructions:
-
Program should be written in file even_numbers.py
-
Function name should be get_even_numbers.
-
Input
Type: List Value: 12
-
Expected Output
Type: List Value: [2,4,6,8,10]
Try solving without for loop.