প্রথমে সেলসিয়াস তাপমাত্রা সেট করুন:
double celsius = 36;
Console.WriteLine("Celsius: " + celsius);
এখন ফারেনহাইটে রূপান্তর করুন:
fahrenheit = (celsius * 9) / 5 + 32;
সম্পূর্ণ উদাহরণ
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Demo {
class MyApplication {
static void Main(string[] args) {
double fahrenheit;
double celsius = 36;
Console.WriteLine("Celsius: " + celsius);
fahrenheit = (celsius * 9) / 5 + 32;
Console.WriteLine("Fahrenheit: " + fahrenheit);
Console.ReadLine();
}
}
}
আউটপুট
Celsius: 36 Fahrenheit: 96.8
সূত্র: °F = (°C × 9/5) + 32