so far I have this and don't laugh please I know i am noob
Code
n1 = int(input("Enter a whole number "))
while n1 in range(0,10):
if n1 % 2 != 0:
print (n1, " is odd")
else:
print (n1, "is even")
and no it isn't working
Write a python program to do the following:
a. Input positive integer number of more than 5 digits and less than 10 digits.
b. Using a While loop check every digit and calculate the following:
• which digit is odd or even.
• how many digits are even and how many are odd.
• the average of the odd digits, and the average of the even digits.
c. Display as output the result that was calculated from the previous step.
An example of the program output if the number entered is 1234321:
Enter a positive integer: 1234321
1 is odd
2 is even
3 is odd
4 is even
3 is odd
2 is even
1 is odd
There are 3 even digits and 4 odd digits.
Average of even odd digits is 2.00 and the average of even digits is 2.67