Identification division.
program-id.temperature11.
environment division.
data division.
working-storage section.
77 ws-a pic 9(3)v9(2).
77 ws-b pic 9(3)v9(2).
procedure division.
main-para.
display " enter degree temperature ".
accept ws-a.
compute ws-b rounded = ( 9/5 * ws-a ) + 32.
display " temperature in fahrenheit celsius " ws-b.
stop run..
algorithm step1 start step2 add 32 to Celsius temperature step3 divide 9 by 5 step4 multiply answer with sum step5 Fahrenheit temperature is obtained step6 stop
To convert temperature from Celsius to Fahrenheit: Multiply the Celsius temperature by 9/5. Add 32 to the result from step 1 to get the Fahrenheit temperature. Algorithm: Fahrenheit = (Celsius * 9/5) + 32.
Sure, here is a simple Python program to convert temperature from degrees Celsius to degrees Fahrenheit: celsius = float(input("Enter temperature in Celsius: ")) fahrenheit = (celsius * 9/5) + 32 print("Temperature in Fahrenheit: ", fahrenheit)
echo "*** Converting between the different temperature scales ***" echo "1. Convert Celsius temperature into Fahrenheit" echo "2. Convert Fahrenheit temperatures into Celsius" echo -n "Select your choice (1-2) : " read choice if [ $choice -eq 1 ] then echo -n "Enter temperature (C) : " read tc # formula Tf=(9/5)*Tc+32 tf=$(echo "scale=2;((9/5) * $tc) + 32" |bc) echo "$tc C = $tf F" elif [ $choice -eq 2 ] then echo -n "Enter temperature (F) : " read tf # formula Tc=(5/9)*(Tf-32) tc=$(echo "scale=2;(5/9)*($tf-32)"|bc) echo "$tf = $tc" else echo "Please select 1 or 2 only" exit 1 fi
Here is a simple C program that accepts temperature in degrees Celsius from the user and then converts and displays the equivalent temperature in Fahrenheit: #include <stdio.h> int main() { float celsius, fahrenheit; printf("Enter temperature in Celsius: "); scanf("%f", &celsius); fahrenheit = (celsius * 9/5) + 32; printf("Temperature in Fahrenheit: %.2f\n", fahrenheit); return 0; } You can compile and run this program to get the desired output.
algorithm step1 start step2 add 32 to Celsius temperature step3 divide 9 by 5 step4 multiply answer with sum step5 Fahrenheit temperature is obtained step6 stop
59ºF = 15.0ºCUse this formula to convert degrees Fahrenheit (F) to degrees Celsius (C): (F - 32) / 1.8 = C
) Define two functions that convert temperatures between degrees Fahrenheit and degrees Celsius. C= (F+40)* 5/9 -40 F= (C+40)* 9/5 -40 > (defun f-to-c (f)(- (/ (* (+ f 40) 5) 9) 40)) > (defun c-to-f (c)(- (/ (* (+ c 40) 9) 5.0) 40))
The word evaluate in the programming language COBOL can be used to replace a nested if statement. Instead of long statement evaluate allows one to shorten the coding required and write cleaner code.
Fahrenheit is written as फेरनहाइट in Hindi.
CLS INPUT "Enter degrees in Celsius:";c INPUT "Enter degrees in Fahrenheit:";f a=(c*1.8)+32 b=5/9(f-32) PRINT c;"degree Celsius=" a;"degree Fahrenheit" PRINT f;"degree Fahrenheit=" b;"degree Celsius" end
To convert temperature from Celsius to Fahrenheit: Multiply the Celsius temperature by 9/5. Add 32 to the result from step 1 to get the Fahrenheit temperature. Algorithm: Fahrenheit = (Celsius * 9/5) + 32.
Sure, here is a simple Python program to convert temperature from degrees Celsius to degrees Fahrenheit: celsius = float(input("Enter temperature in Celsius: ")) fahrenheit = (celsius * 9/5) + 32 print("Temperature in Fahrenheit: ", fahrenheit)
20 degrees Fahrenheit - 30 degrees Fahrenheit = -10 degrees Fahrenheit
Each question carries 10 marks. Explain the environment Division with example. Explain the Data Division with an example. Explain the various types of Move statements. Write a COBOL program to find a given integer is odd or even. An input file consists of the following Employee name, Employee number, Basic pay. Write a COBOL program to create an Indexed file which consists of Employee-name, Employee-number, Basic-pay and DA (DA = 25% of Basic-pay) Assume that an organisation has 20 departments. Each department has 5 stores. You are provided with total monthly sales of each stores for the month December 2000. Write a COBOL program to read the data, to write the sales report department wise and also write the total sales of the organisation.
just think and write something good
It depends on the target platform. If you want to use MF COBOL on the mainframe then the answer is none, MF supports the mainframe as a target by using MF EEE. You write and unit test the code on the PC and then send the source off to the mainframe for compilation and final testing.