Write a Pseudocode or the algorithm of the computer program
Write a Pseudocode or the algorithm of the computer program that will change a Fahrenheit temperature to Celsius. Write two versions of the program, one in Java and one in C++.
Please can you send me the pseudocode or the algorithm of the above conversion both in Java and C++?
Solution
Declare C As Float Declare F As Float Declare Temperature As Float Write “Temperature Conversion Program” Write “This program will convert a temperature, entered in” Write “degrees Celsius, to degrees Fahrenheit.” Write “enter a temperature number or press -999 to quit” Input Temperature While Temperature != -999 Set F = 9 * C/ 5 + 32 Write “The Temparture in Fahrenheit is” End While --------------------- // Celsius to Fahrenheit conversion in Java import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class CelsiusToFahrenheit { public static void main(String[] args) throws IOException{ BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); System.out.print(\"Please enter temperature in Celsius : \"); double celsius = Double.parseDouble(reader.readLine()); double fahrenheit = (9.0/5.0)*celsius + 32; System.out.println(\"Temperature in Fahrenheit is : \"+fahrenheit); } }