At Westonci.ca, we make it easy to get the answers you need from a community of informed and experienced contributors. Get immediate and reliable answers to your questions from a community of experienced experts on our platform. Explore comprehensive solutions to your questions from a wide range of professionals on our user-friendly platform.
Sagot :
Answer:
See attachment for complete solution
Explanation:
The program in your question is unreadable.
So, I started from scratch (see attachment for complete solution)
Using the attached file as a point of reference.
The program has 15 lines
Line 1: Prompt the user for highway number (as an integer)
Line 2: Convert the user input to string
Line 3: Check if highway number is outside 1-999
Line 4: If line 3 is true, print a notice that the input is outside range
Line 5: If line 3 is not true
Line 6: Check if the number of highway digits is 2.
Line 7: If true, Check if highway number is an even number
Line 8: If even, print that the highway is primary and heads east/west
Line 9: If highway number is odd number
Line 10: Print that the highway is primary and heads north/south
Line 11: If the number of highway digits is 3
Line 12: Check if highway number is an even number
Line 13: If even, print that the highway is auxiliary and heads east/west
Line 14: If highway number is odd number
Line 15: Print that the highway is auxiliary and heads north/south
See attachment for complete program
Thank you for choosing our service. We're dedicated to providing the best answers for all your questions. Visit us again. We appreciate your time. Please revisit us for more reliable answers to any questions you may have. Thank you for trusting Westonci.ca. Don't forget to revisit us for more accurate and insightful answers.