Question: When the user first runs the program, you will display the following menu:Welcome to 1 to 4 Demultiplexer!a ) Compute and Display the outputsb )

When the user first runs the program, you will display the following menu:Welcome to 1 to 4 Demultiplexer!a) Compute and Display the outputsb) QuitDepending on the option given by the user, your program will work as follows:Option 'a': When the user chooses this option, your program will first ask you to enter 3-digit binary inputs. If more than 3 bits is entered, then your program should print an error message and ask the user to re-enter the input. 3 digits will be used as 3 inputs required by the demultiplexer. First digit is S1, the second digit is SO and the last digit is D.The inputs can be entered in base 2 or base 10. If the user enters in base 2, then you will not need to make base conversions. However, if the user enters in base 10, then you will need to convert it to binary. If the user enters a value >7 in base 10, then your program will display"not possible to convert it to 3-digit binary number" and will ask the user to re-enter the value again.Which base will you use to enter input (base 2 or base 10]?2Please enter your input: 010From the above table, the output Y becomes l if all of the digits Sland SO and D are one.Thus, we can write its expression asYO=(NOT SI) AND (NOT SO) AND DY1=[NOT S1) AND SO AND DY2= S1 AND (NOT SO) AND DY3= S1 AND SO AND DFor your reference, the truth table for bitwise AND and NOT are as follows:
When the user first runs the program, you will

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 Programming Questions!