Question: Fix the errors in the pseudocode! I have to fix the codes that cause errors which all have comments in bold beside them. If you

Fix the errors in the pseudocode! I have to fix the codes that cause errors which all have comments in bold beside them. If you could enter the fixed code into the original code so that i could just copy and paste it into a word document, that would be amazing. The instructions of the code are below with an example run. The code that needs fixing is below that.

Fix the errors in the pseudocode! I have to fix the codes

that cause errors which all have comments in bold beside them. If

THE ISSUES IN THE CODE ARE COMMENTS IN BOLD.

---------

START

DECLARE REAL temp

DECLARE STRING initialScale

REPEAT

DISPLAY Please enter a temperature greater or equal to than 0.00 Kelvin, -273.15 C, -459.67 F, 0.00 Rankine, 559.73 Delisle, -90.14 Newton, -218.14 Reaumur, and -135.9 Romer

GET temp//You need to get the temperature and the scale

UNTIL temp>= 0.00 Kelvin, OR temp >= 0.00 C, OR temp >= 0.00 F, OR temp >= 0.00 Rankine, OR temp >= 0.00Delisle, OR temp >= -0.00 Newton, OR temp >= -0.0014 Reaumur, OR temp >= 0.00 Romer//You cannot compare a number and a STRING in the same compare. Also, the user did not enter a STRING. You just got the REAL value from the user and stored it into temp. -2

tempConverter()//This is not a proper module call. -2

You do not allow the user to repeat the program. -10

STOP

BEGIN tempConverter()//This is not a proper module header. -2

DECLARE STRING targetScale

DECLARE INT convTemp

REPEAT

DISPLAY Please enter Kelvin, Fahrenheit, Celsius, Kelvin, Rankine, Delisle, Newton, Raumur, or Rmer to convert your temperature.

GET targetScale

UNTIL targetScale = Fahrenheit, OR targetScale = Celsius, OR targetScale = Kelvin, OR targetScale = Rankine, OR targetScale = Delisle, OR targetScale = Newton, OR targetScale = Raumur, OR targetScale = Rmer

IF initialScale = Celsius THEN//Where does initialScale come from? It is in the main program and not visible in this module. You also did not ask the user for it as input. -5

IF targetScale = Fahrenheit THEN

convTemp = [temp] 9?5 + 32

ELSE

IF targetScale = Kelvin THEN

convTemp = [temp] + 273.15

ELSE

IF targetScale = Rankine THEN

convTemp = ([temp] + 273.15) 9?5

ELSE

IF targetScale = Delisle THEN

convTemp = (100 ? [temp]) 3?2

ELSE

IF targetScale = Newton THEN

convTemp = [temp] 33?100

ELSE

IF targetScale = Raumur THEN

convTemp = [temp] 4?5

ELSE

IF targetscale = Rmer THEN

convTemp = [temp] 21?40 + 7.5

ENDIF

ENDIF

ENDIF

ENDIF

ENDIF

ENDIF

ENDIF

ENDIF

CODE continues but had to post as pictures because chegg limits the word count. The rest of the code can been seen through the screenshots below.

you could enter the fixed code into the original code so that

i could just copy and paste it into a word document, that

would be amazing. The instructions of the code are below with an

example run. The code that needs fixing is below that. THE ISSUES

IN THE CODE ARE COMMENTS IN BOLD. --------- START DECLARE REAL temp

Thank you to all of those who respond.

Write the IPO and pseudocode algorithm for a temperature conversion program that will allow the user to enter in an input temperature in one scale and then a target scale to convert to. The program would then convert to the target scale. EG If I were to enter 32.0 Fahrenheit as my input temperature and Celsius as my target scale the program would return "32.0 degrees Fahrenheit is equal to 0.00 degrees Celsius. Your program must support conversion to and from the following scales Fahrenheit, Celsius, Kelvin, Rankine, Delisle, Newton, Raumur, Rmer Your program must validate that the user has entered a proper scale You will need the temperature conversion formulas from the following site https://en.wikipedia.org/wiki/Conversion_of_units_of_temperature Your program must validate that the user has entered a proper scale for both the input scale and the target scale. Your program must also validate that the user has not entered a temperature that is below absolute zero. You can find the temperatures for absolute zero for each of the scales at the above web site Your program must allow the user to repeat this program as many times as they would like You will also need to show a paper check of the program working HINTS!!!! Convert from the input scale into an intermediate scale, such as the Kelvin scale, and then from that scale to the target scale. That will avoid converting directly from each scale into every other sca When validating for absolute zero, first convert to the intermediate scale. That will avoid the need of directly checking for absolute zero in every scale . Write the IPO and pseudocode algorithm for a temperature conversion program that will allow the user to enter in an input temperature in one scale and then a target scale to convert to. The program would then convert to the target scale. EG If I were to enter 32.0 Fahrenheit as my input temperature and Celsius as my target scale the program would return "32.0 degrees Fahrenheit is equal to 0.00 degrees Celsius. Your program must support conversion to and from the following scales Fahrenheit, Celsius, Kelvin, Rankine, Delisle, Newton, Raumur, Rmer Your program must validate that the user has entered a proper scale You will need the temperature conversion formulas from the following site https://en.wikipedia.org/wiki/Conversion_of_units_of_temperature Your program must validate that the user has entered a proper scale for both the input scale and the target scale. Your program must also validate that the user has not entered a temperature that is below absolute zero. You can find the temperatures for absolute zero for each of the scales at the above web site Your program must allow the user to repeat this program as many times as they would like You will also need to show a paper check of the program working HINTS!!!! Convert from the input scale into an intermediate scale, such as the Kelvin scale, and then from that scale to the target scale. That will avoid converting directly from each scale into every other sca When validating for absolute zero, first convert to the intermediate scale. That will avoid the need of directly checking for absolute zero in every scale

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!