Kali ini w akan ngasih source code buat ngukur ideal berat badan di tubuh kita
dengan software borland
#include
#include
#include
main()
{
int tb,bb,x;
char gen,lg;
atas:
clrscr();
cout<<"MALE/FEMALE [M/F] : ";cin>>gen;
cout<<"Masukan Tinggi Badan Anda : ";cin>>tb;
cout<<"Masukan Berat Badan Anda : ";cin>>bb;
clrscr();
x=(tb-100)-10*(tb-100)/100;
if (bb
cout<<"\t =>KURUS<= \n\nANDA HARUS MENAIKAN "<<(x-bb)<<"KG SUPAYA BERAT BADAN ANDA MENJADI IDEAL";
else if (bb=x)
cout<<"\t =>
else if (bb>x)
cout<<"\t =>GEMUK<= \n\nANDA HARUS MENURUNKAN "<<(bb-x)<<"KG SUPAYA BERAT BADAN ANDA MENJADI IDEAL";
else
cout<<"=>OVER SIZE<=";
cout<<"\n\nIngin Hitung Lagi [Y/N] : ";cin>>lg;
if (lg=='Y'||lg=='y')
goto atas;
else
cout<<"\n\t THANK YOU \nPLEASE CLOSE THIS PROGRAM NOW"<
getch();
}
Silahkan Berkomentar Pada Form Komentar dengan sopan dan santun .. No Spam .... !!! thank's @Admin
EmoticonEmoticon