210k views
4 votes
Write a pseudocode for example 2 of Super Simple CPU Applet. 4. [4] (Temperature Conversion) Write a pseudocode that: a. reads a Celsius degree from input b. converts it to Fahrenheit (you need the formula to convert from Celsius to Fahrenheit) c. displays the result as show in the sample run below Note: 25 is an example input for Celsius in the sample run, your program should work correctly for any input. Here is a sample run: Enter Celsius degree: 25 Degree in Fahrenheit is 77.0

User Brettfazio
by
8.4k points

2 Answers

1 vote

Answer: In computer science and programming, pseudocode is a detailed description of a computer program or algorithm that utilizes natural language. Pseudocode allows programmers to plan and strategically design their codes before writing the actual code. The purpose of this essay is to provide a detailed pseudocode solution for Example 2 of the Super Simple CPU Applet, specifically for the temperature conversion program that reads a Celsius degree, converts it to Fahrenheit, and displays the result.Step 1: Begin the Program

Step 2: Prompt the user to enter the Celsius degree

Step 3: Read Celsius degree from the input and store it in a variable called “Celsius”

Step 4: Convert Celsius to Fahrenheit using the formula: Fahrenheit = (Celsius * 9/5) + 32

Step 5: Store the Fahrenheit value in a variable called “Fahrenheit”

Step 6: Display the result as “Degree in Fahrenheit is [Fahrenheit]” Begin the Program

also, this is what it should look like

Convert Celsius to Fahrenheit using the formula: Fahrenheit = (Celsius * 9/5) + 32

Store the Fahrenheit value in a variable called “Fahrenheit”

Display the result as “Degree in Fahrenheit is [Fahrenheit]”

End Program

Explanation: i don't need one. * its not complicated and i hoped this helps*

User Cruizer
by
8.1k points
1 vote

Answer:Sure, here is a simple pseudocode example that accomplishes the task:

```

Procedure Convert Celsius to Fahrenheit:

Begin

Display "Enter Celsius degree:"

Read Celsius from input

Fahrenheit ← (Celsius * 9/5) + 32

Display "Degree in Fahrenheit is ", Fahrenheit

End

```

This pseudocode follows these steps:

1. It prompts the user to enter a degree in Celsius.

2. It reads the input.

3. It applies the formula for converting Celsius to Fahrenheit, which is `F = (C * 9/5) + 32`.

4. It displays the result, indicating that it is in Fahrenheit.

User Jbindel
by
7.5k points