Cah cilik belajar ngoding6

Program ATM :

#include <cstdlib>
#include <iostream>

/* run this program using the console pauser or add your own getch, system("pause") or input loop */
using namespace std;

int main(int argc, char** argv) {
    int password;
    int i;
    cout<<"\t\t\t==> SELAMAT DATANG DI ATM<==\n\n"<<endl;
    int pass=123456;
    i=i;
    do{
        cout<<"    Masukkan Password anda : "<<endl;
        cin>>password;
        if(password==pass){
            cout<<"==>selamat anda berhasil masuk di menu ATM<<=="<<endl;
    }
    else {
    cout<<"Password anda salah,..coba lagi.."<<endl;
    i=i+i;
    }
        }
        while (i<=3);
        cout<<"ATM TERBLOKIR..!!! Segera hubungi costumer service"<<endl;
       
return 0 ;
    }

Gimana?? bisa dicompiler ngk?
 Hasilnya sama gak dengan yang diatas.


^_^ Selamat Belajar

Komentar

Postingan populer dari blog ini

Studi Case

Mencari titik tengah sebuah garis

Pemrograman Web Dinamis