Minggu, 12 November 2017

Program Konversi Suhu dengan C

#include <stdio.h>
void main()
{
int celcius;
int kelvin;
int farenheit;
int reamur;
printf("Konversi Suhu");
printf("\n");
printf("Input Suhu Celcius : ");
scanf("%i", &celcius);
kelvin = celcius+273;
reamur = celcius*0.8;
farenheit = (1.8*celcius)+32;
printf("\n");
printf("\nKelvin : %i", kelvin);
printf("\nReamur : %i", reamur);
printf("\nFarenheit : %i", farenheit);
getch();
}

Tidak ada komentar:

Posting Komentar