Question: Python help Create a list of the odd numbers between 1 and n (include 1 as well as n -- if it's odd-- in the
Python help
Create a list of the odd numbers between 1 and n (include 1 as well as n -- if it's odd-- in the list). Associate the list with the variable odds.
this is what I have so far but it's not correct
odds = [] for numbers in range(1,n): if numbers % 2 != 0: odds.append(numbers)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
