Advertisement
savovaap_

From Celsius to Fahrenheit

Mar 29th, 2023
732
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.25 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5.     float celsius, fahrenheit;
  6.  
  7.     printf("Enter T in celsius - ");
  8.     scanf("%f", &celsius);
  9.  
  10.     fahrenheit = ((celsius * 9)/5) + 32;
  11.  
  12.     printf("\n %.2f C = %.2f F", celsius, fahrenheit);
  13.  
  14.     return 0;
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement