1. Raptor
#include <iostream>
using namespace std;
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int main(int argc, char** argv) {
cout<<"\t\tProgram menjumlahkan bilangan "<<endl<<endl;
int a;
int b;
int c;
int jumlah;
cout<<"masukkan bilangan A =";
cin>>a;
cout<<"masukan bilangan B =";
cin>>b;
cout<<"masukan bilangan C =";
cin>>c;
cout<<"JUMLAH = ";
cout<<a+b+c;
return 0;
}
using namespace std;
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int main(int argc, char** argv) {
cout<<"\t\tProgram menjumlahkan bilangan "<<endl<<endl;
int a;
int b;
int c;
int jumlah;
cout<<"masukkan bilangan A =";
cin>>a;
cout<<"masukan bilangan B =";
cin>>b;
cout<<"masukan bilangan C =";
cin>>c;
cout<<"JUMLAH = ";
cout<<a+b+c;
return 0;
}
1.Raptor
2.Dev c++
#include <iostream>
using namespace std;
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int main(int argc, char** argv) {
int a;
int b;
cout<<"\t\tPROGRAM PERKALIAN "<<endl<<endl;
cout<<"masukkan bilangan A =";
cin>>a;
cout<<"masukkan bilangan B =";
cin>>b;
cout<<"Jumlah perkalian = ";
cout<<a*b;
return 0;
}
1. Raptor
2.Dev c++
#include <iostream>
using namespace std;
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int main(int argc, char** argv) {
float m,cm,inchi;
cout<<"\t\tprogram mengubah meter ke cm dan meterke inchi"<<endl<<endl;
cout<<"Masukkan nilai meter = ";cin>>m;
cm = m*100;
inchi = (m*100)/2.54;
cout<<"\nHasil Meter ke cm = "<<cm;
cout<<"\nHasil Meter ke inchi = "<<inchi;
return 0;
}
Tidak ada komentar:
Posting Komentar