Write a program in Java to input a number. Display all the digits of the number
by stating whether it is an even or an odd digit by using do while loop (Use
Scanner class).
Sample input: 891
Sample output:
1: an odd digit
9: an odd digit
8: an even digit

Answers & Comments


Add an Answer


Please enter comments
Please enter your name.
Please enter the correct email address.
You must agree before submitting.

Helpful Social

Copyright © 2024 EHUB.TIPS team's - All rights reserved.