Question: #Write program prompting user to enter a 3 - digit number ( e . g . , 1 5 0 , 9 7 5 ,

#Write program prompting user to enter a 3-digit number (e.g.,150,975,333,100,396)
#Extract and display the first digit, the second digit, and the third digit
#Use //(integer division) and %(remainder) to extract each digit
#Hints: Use //100 to get the first digit. Use %100 and //10 to get the second digit. Use something similar to get the the third digit
#Display result in format below
#Examples:
#Enter three digit number: 150
#First digit: 1
#Second digit: 5
#Third digit: 0
#Enter three digit number: 975
#First digit: 9
#Second digit: 7
#Third digit: 5

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!