Ler uma temperatura em Celsios e converter em Fahrenheit em C++

Ler uma temperatura em graus Centígrados e apresentá-la convertida em graus Fahrenheit. A fórmula de conversão é: F = (9 * C + 160) / 5, onde F é a temperatura em Fahrenheit e C é a temperatura em Centígrados. Resulução:

#include <cstdlib>
#include <iostream>
int main()

{
float c=0,f=0,;

printf(“Digite o valor da temperatura em Celsios: “);
scanf(“%f”,&c);

f=(9*c+160)/5;

printf(“O valor da temperatura em Fahrenheit é: %f\n\n”,f);

system(“PAUSE”);
return EXIT_SUCCESS;
}

1 Resposta para “Ler uma temperatura em Celsios e converter em Fahrenheit em C++”


  1. 1 romi 12, Outubro 2007 às 3:16 pm

    muy buena pero mas imformacion por favor la necesito okey


Deixe uma resposta




Buscar no blog:

a

© Copyright 2007, Leandro Jonk