//Program Pemesanan Tiket Bioskop
//created by galih
#include <iostream.h>
#include <conio.h>
void main()
{
int film,film1,tiket;
float harga,total;
char *nj;
a:
clrscr();
cout<<"Pilihan Film : \n";
cout<<"1. Manca : \n";
cout<<"2. Indo : \n";
cout<<"Masukkan Pilihan Film : "; cin>>film;
if (film == 1)
{
b:
clrscr();
cout<<"Pilihan Film : \n";
cout<<"1. Residen Evil \n";
cout<<"2. The Avanger \n";
cout<<"3. Spider Man \n";
cout<<"Masukkan Pilihan Film : "; cin>>film1;
if(film1 == 1)
{
nj = "Residen Evil";
}
else if (film1 == 2)
{
nj = "The Avanger";
}
else if (film1 == 3)
{
nj = "Spider Manl";
}
}
else if (film == 2)
{
clrscr();
cout<<"Pilihan Film : \n";
cout<<"1. 5 CM \n";
cout<<"2. Langit ke 7 \n";
cout<<"3. Perahu Kertas \n";
cout<<"Masukkan Pilihan Film : "; cin>>film1;
if(film1 == 1)
{
nj = "5 CM";
}
else if (film1 == 2)
{
nj = "Langit Ke 7";
}
else if (film1 == 3)
{
nj = "Perahu Kertas";
}
}
else
{
cout<<"Pilihan anda salah";
getch();
goto a;
}
clrscr();
cout<<"Jadwal : \n";
cout<<"1. Senin - Jumat = 20.000\n";
cout<<"2. Sabtu - Minggu = 30.000\n";
cout<<"Masukkan Pilihan Film : "; cin>>film1;
if (film1 == 1)
{
cout<<"Harga Tiket : 20.000 \n";
harga = 20000;
}
else if (film1 == 2)
{
cout<<"Harga Tiket : 30.000 \n";
harga = 30000;
}
else
{
cout<<"Pilihan Anda Salah";
}
cout<<"\n";
cout<<"Masukkan Jumlah Tiket : "; cin>>tiket;
total = harga * tiket;
clrscr();
cout<<"Telah di Beli tiket Cinema21 dengan Judul "<<"'"<<nj<<"'"<<endl;
cout<<"sebanyak "<<tiket<<". sehingga total yang harus dibayar adalah : "<<total<<endl;
getch();
goto a;
}
Posting Komentar