Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace ScriptCSharp
- {
- class Program
- {
- static void Main(string[] args)
- {
- /*27 – Ler uma temperatura em graus Celsius e apresentá-la convertida em graus Kelvin.
- A fórmula de conversão é: K = C + 273.15, sendo C a temperatura em Celsius e K a
- temperatura em Kelvin.
- */
- Console.Write("Qual a temperatura em graus Celsius: ");
- double cel = double.Parse(Console.ReadLine());
- double kel = cel + 237.15;
- Console.WriteLine("A temperatura em graus Celsius, convertida para Kelvin é: "+ kel);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement