RSS

Konversi Suhu : Celcius-Fahrenheit-Reamur-Kelvin

17 Apr

Program konversi suhu menggunakan C++ :

#include <iostream>
#include <string>

using namespace std;
int main()
{
float k,K;
float r,R;
float c,C;
float f,F;

cout<<“Masukkan Nilai Celcius = “;
cin >> C;
F =(C*1.8)+32;
R =C*0.8;
K =C+273.15;
cout << “Fahrenheit =”<<F << endl;   cout << “Reaumur =”<<R << endl;   cout << “kelvin =”<<K << endl;

system(“pause”);
return 0;
}

 
Tinggalkan komentar

Ditulis oleh pada April 17, 2012 in algoritma dan pemrograman

 

Tinggalkan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s

 
%d blogger menyukai ini: