TheMalva

Ejercicio_11

Apr 22nd, 2015
299
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.41 KB | None | 0 0
  1. //Diseñar un algoritmo que realice la siguiente conversión: una temperatura dada en grados Celsius a grados Fahrenheit.
  2. //F°= 9 / 5 * C° + 32
  3.  
  4. #include <stdio.h>
  5. #include <stdlib.h>
  6.  
  7. int main()
  8. {
  9.     float tC=0, tF=0;
  10.     printf("Ingrese la temperatura en grados Celsius: ");
  11.     scanf("%f", &tC);
  12.     tF = 9 / 5 * tC + 32;
  13.     printf("La temperatura en grados Fahrenheit es de: %f", tF);
  14.     return 0;
  15. }
Advertisement
Add Comment
Please, Sign In to add comment