diff --git a/Convert_Celsius_To_Fahrenheit.cpp b/Convert_Celsius_To_Fahrenheit.cpp new file mode 100644 index 0000000..2fa7cad --- /dev/null +++ b/Convert_Celsius_To_Fahrenheit.cpp @@ -0,0 +1,58 @@ +#include +#include +#include +#include +#include +#include +using namespace std; +#define ll long long int +#define lt long long +#define pi (3.141592653589) +#define mod 1000000007 + +#define tc \ + int t; \ + cin >> t; \ + while (t--) + +#define lull NULL + +#define float double + +#define pb push_back + +#define mp make_pair + +#define ff first + +#define ss second + +#define all(c) c.begin(), c.end() + +#define min3(a, b, c) min(c, min(a, b)) + +#define min4(a, b, c, d) min(d, min(c, min(a, b))) + +#define fir(i, n) for (int i = n - 1; i >= 0; i--) + +#define fi(i, n) for (int i = 0; i < n; i++) +#define fin(j, n) for (int i = j; i <= n; i++) + +#define fast ios_base::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr); + +// function to convert Celsius +// scale to Fahrenheit scale +float Cel_To_Fah(float N) +{ + return ((N * 9.0 / 5.0) + 32.0); +} + +// Driver code +int main() +{ + float N = 20.0; + + // Function call + cout << Cel_To_Fah(N); + return 0; +}