Jumat, 29 Desember 2017

                                                   SIMULASI BOM SEDERHANA 
                                                                       DEV C++


#include <conio.h>
#include <windows.h>
#include <cstdlib>
#include <iostream>
#include<time.h> 

using namespace std;

void wait ( double seconds )
{
  clock_t endwait;
  endwait = clock () + seconds * CLOCKS_PER_SEC ;
  while (clock() < endwait) {}
}

main()
{
char hrf;
int i;
system("color 09");
cout<<""<<endl; cout<<""<<endl; 
cout<<"\t \t \t                         Asalammua'laikum Wr.Wb'"<<endl;
getch();
system("cls");
system("color 17");
cout<<"\t \t \t jawab pertanyaan ini dengan baik dan benar!!"<<endl;
getch();

 system("cls");
 system("color 0e");
cout<<"Apa nama kerja paksa pada jaman penjajahan jepang="<<endl;
cout<<"a. kerja rodi"   <<endl
<<"b. kerja romusha"<<endl;
cout<<"tuliskan jawaban (a/b)"<<endl;
cin>>hrf;
 system("cls");
if (hrf=='b')
{
system("color 0E");
  cout <<""<<endl; cout <<""<<endl
         <<"\t \t \t \t \t ___________________________"<<endl
         <<"\t \t \t \t \t |   jawaban anda benar    |"<<endl
    <<"\t \t \t \t \t |  anda selamat dari bom! |"<<endl
       <<"\t \t \t \t \t ***************************"<<endl;
   }
   else{
   
    for( i=5;i>=0;i--){ 
            system("cls");
            system("color 0c");
            cout<<"\t \t \t     ---------jawaban anda salah-----------"<<endl;
            cout<<"\t \t \t     ----BOM AKAN MELEDAK DALAM WAKTU:-----"<<endl;
            cout<<"\n\t\t\t\t\t \t  "<<i;wait(1);
            

}

    for(i=1;i<6;i+2){

    cout<<"BOOOOOOMMMMMMMMMMMMMMMMMMMMMMMMMMMMM HANCUR SEMUANYA ";
    
}
}
getch();

}

Tidak ada komentar:

Posting Komentar

                                   PERCABANGAN KONVERSI SUHU LENGKAP #include <iostream>  using namespace std; int main (int ...