-
Lenguaje
Pascal
-
Descripción
Convierte grados centígrados a grados Fahrenheit y a kelvins
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
2
3
4
5
6
7
8
9
10
11
12
13
14
15
program GradosCentigradosAGradosFahrenheitYAKelvins;
uses crt;
var grados_centigrados, grados_fahrenheit, kelvins : real;
begin
write ('Ingresa el valor de grados centigrados: ');
readln (grados_centigrados);
kelvins := grados_centigrados+273.15;
grados_fahrenheit := 1.8*grados_centigrados+32;
writeln ('Valor de grados fahrenheit: ', grados_fahrenheit:0:6);
writeln ('Valor de kelvins: ', kelvins:0:6);
writeln;
write ('Presiona una tecla para terminar . . . ');
readkey;
end.
uses crt;
var grados_centigrados, grados_fahrenheit, kelvins : real;
begin
write ('Ingresa el valor de grados centigrados: ');
readln (grados_centigrados);
kelvins := grados_centigrados+273.15;
grados_fahrenheit := 1.8*grados_centigrados+32;
writeln ('Valor de grados fahrenheit: ', grados_fahrenheit:0:6);
writeln ('Valor de kelvins: ', kelvins:0:6);
writeln;
write ('Presiona una tecla para terminar . . . ');
readkey;
end.