Write a python program that first asks the user how many numbers should be entered. Then the program will read that many numbers from the user, and print the numbers which are even, odd and a multiple of 8. For example, if user input is 5, your program should read 5 numbers and check if they are even,odd and a multiple of 8. You must use loops to solve this problem. Sample Input: No. of Inputs = 5 User then should be asked to input 5 numbers and print accordingly in the following manner Sample Input Sample Output 10 10 is an even number but NOT a multiple of 8 16 16 is an even number and a multiple of 8 35 35 is an odd number and NOT a multiple of 8 8 8 is an even number and a multiple of 8 13 13 is an odd number and NOT a multiple of 8
Write a python program that first asks the user how many numbers should be entered. Then the program will read that many numbers from the user, and print the numbers which are even, odd and a multiple of 8. For example, if user input is 5, your program should read 5 numbers and check if they are even,odd and a multiple of 8. You must use loops to solve this problem.
Sample Input:
No. of Inputs = 5
User then should be asked to input 5 numbers and print accordingly in the following manner
Sample Input Sample Output
10 10 is an even number but NOT a multiple of 8
16 16 is an even number and a multiple of 8
35 35 is an odd number and NOT a multiple of 8
8 8 is an even number and a multiple of 8
13 13 is an odd number and NOT a multiple of 8
Enter 5 numbers:
10
16
35
8
13
10 is even number but NOT a multiple of 8
16 is even number and a multiple of 8
35 is odd number and NOT a multiple of 8
8 is even number and a multiple of 8
13 is odd number and NOT a multiple of 8
Step by step
Solved in 2 steps with 1 images