#include<iostream>
#include<conio.h>
#include<stdio.h>
#include <windows.h>
#define maks 80
using namespace std;
class EnqueueBus
{
private :
int bus[maks];
int kepala;
int ekor;
char nama[30];
string nomer;
public:
EnqueueBus();
void gotoxy( int column, int line );
bool kosong();
bool penuh();
void busMasuk(int);
int busJalan();
void print();
void hapusSemuaAntrian();
void header();
void Menu();
void waktu(int);
int jam;
};
void EnqueueBus::gotoxy( int column, int line )
{
COORD coord;
coord.X = column;
coord.Y = line;
SetConsoleCursorPosition(
GetStdHandle( STD_OUTPUT_HANDLE ),
coord
);
}
EnqueueBus :: EnqueueBus()
{
kepala = -1;
ekor = -1;
Menu();
}
bool EnqueueBus :: kosong()
{
if (ekor == -1) return 1;
else return 0;
}
bool EnqueueBus:: penuh()
{
if(ekor == maks -1 ) return 1;
else return 0;
}
void EnqueueBus :: waktu(int jam)
{
if (jam==1){cout<<"06.00";
}
else if (jam==2){cout<<"07.15";
}
else if(jam==3){cout<<"07.40";
}
else if(jam==4){cout<<"08.00";
}
else if(jam==5){cout<<"09.00";
}
else if(jam==6){cout<<"09.30";
}
else if (jam==7){cout<<"10.00";
}
else if (jam==8){cout<<"10.30";
}
else if (jam==9){cout<<"10.45";
}
else if (jam==10){cout<<"11.30";
}
else if (jam==11){cout<<"12.30";
}
else if (jam==12){cout<<"14.30";
}
else if (jam==13){cout<<"15.00";
}
else if (jam==14){cout<<"15.30";
}
else if (jam==15){cout<<"15.45";
}
else if (jam==16){cout<<"16.30";
}
else if (jam==17){cout<<"16.45";
}
else if (jam==18){cout<<"17.00";
}
else if (jam==19){cout<<"17.30";
}
else if (jam==20){cout<<"18.00";
}
else if (jam==21){cout<<"18.30";
}
else{cout<<"Pilihan tidak teredia";
}
}
void EnqueueBus::hapusSemuaAntrian()
{
if(kosong() == 1)
{
gotoxy(25,12);
cout << "Belum Ada Antrian Tidak Bisa Dihapus";
}
else{
kepala = ekor = -1;
gotoxy(25,12);
cout << "Antrian Bus Telah Dihapus Semua" << endl;
}
}
void EnqueueBus::busMasuk(int jalurbus)
{
if(kosong() == 1)
{
kepala = 0;
ekor = 0;
bus[ekor] = jalurbus;
if(jalurbus == 1)
{
cout << "Jalur 1 : Glagah-Kusumanegara-Malioboro-Kaliurang" ;
cout<<endl;
}
else if(jalurbus == 2)
{
cout << "Jalur 2 : Jl.Pramuka-Umbulharjo-Veteran-Gejayan";
cout<<endl;
}
else if(jalurbus == 3)
{
cout << "Jalur 3 : CondongCatur-BabarSari-Janti-Kusumanegara";
cout<<endl;
}
else if(jalurbus == 4)
{
cout << "Jalur Bus 4 : Gejayan-UGM-BulakSumur-KaliUrang";
cout<<endl;
}
else if(jalurbus == 5)
{
cout << "Jalur Bus 5 : Jl.Kusumanegara-Gembira loka-Jogja Expo Center";
cout<<endl;
}
else if(jalurbus == 6)
{
cout << "Jalur Bus 6 : Pasar Kembang-Malioboro-Taman Pintar";
cout<<endl;
}
else if(jalurbus == 7)
{
cout << "Jalur Bus 7 : Alun-alun Utara -Pasar Ngasem-Wirobrajan";
cout<<endl;
}
else if(jalurbus == 8)
{
cout << "Jalur Bus 8 : Jl.Sagan-UNY-Ring road Utara-Kampus Amikom";
cout<<endl;
}
else if(jalurbus == 9)
{
cout << "Jalur Bus 9 : RS.Bethesda-Jl.Sagan-RS.Panti Rapih";
cout<<endl;
}
else if(jalurbus == 10)
{
cout << "Jalur Bus 10 : Kridosono-Gramedia-UGM";
cout<<endl;
}
else if(jalurbus == 11)
{
cout << "Jalur Bus 11 : Jl.C.Simanjutak-Jl.Kaliurang-RS.Sardjito";
cout<<endl;
}
else if(jalurbus == 12)
{
cout << "Jalur Bus 12 : SMA N 3 Yogyakarta-Gramedia-Mirota Kampus";
cout<<endl;
}
else if(jalurbus == 13)
{
cout << "Jalur Bus 13 : Jl.Pramuka-Jl.Dr.Soepomo-Jl.Kapas";
cout<<endl;
}
else if(jalurbus == 14)
{
cout << "Jalur Bus 14 : kampus UIN-Ambarokmo Plaza-Jl.Solo";
cout<<endl;
}
else if(jalurbus == 15)
{
cout << "Jalur Bus 15 : Jl.Kusumaegara-Halte Senopati-Taman Budaya Jogja";
cout<<endl;
}
else if(jalurbus == 16)
{
cout << "Jalur Bus 16 : Jl.Kusumaegara-Taman Siswa-Rumah Sakit Jogja Wirosaban";
cout<<endl;
}
else if(jalurbus == 17)
{
cout << "Jalur Bus 17 : UIN-Galeria Mall-Masjid UGM";
cout<<endl;
}
else if(jalurbus == 18)
{
cout << "Jalur Bus 18 : PGSD USD-Ring Road Utara-Monjali";
cout<<endl;
}
else if(jalurbus == 19)
{
cout << "Jalur Bus 19 : Jalan Kaliurang-Taman Lampion-Taman Sleman";
cout<<endl;
}
else if(jalurbus == 20)
{
cout << "Jalur Bus 20 : Jalan Kaliurang-Jalan Magelang-Borobudur";
cout<<endl;
}
else
{
cout << "Jalur Bus Tidak Tersedia";
}
}
else if(penuh() == 0)
{
ekor++;
bus[ekor] = jalurbus;
if(jalurbus == 1)
{
cout << "Jalur 1 : Glagah-Kusumanegara-Malioboro-Kaliurang" ;
cout<<endl;
}
else if(jalurbus == 2)
{
cout << "Jalur 2 : Jl.Pramuka-Umbulharjo-Veteran-Gejayan";
cout<<endl;
}
else if(jalurbus == 3)
{
cout << "Jalur 3 : CondongCatur-BabarSari-Janti-Kusumanegara";
cout<<endl;
}
else if(jalurbus == 4)
{
cout << "Jalur Bus 4 : Gejayan-UGM-BulakSumur-KaliUrang";
cout<<endl;
}
else if(jalurbus == 5)
{
cout << "Jalur Bus 5 : Jl.Kusumanegara-Gembira loka-Jogja Expo Center";
cout<<endl;
}
else if(jalurbus == 6)
{
cout << "Jalur Bus 6 : Pasar Kembang-Malioboro-Taman Pintar";
cout<<endl;
}
else if(jalurbus == 7)
{
cout << "Jalur Bus 7 : Alun-alun Utara -Pasar Ngasem-Wirobrajan";
cout<<endl;
}
else if(jalurbus == 8)
{
cout << "Jalur Bus 8 : Jl.Sagan-UNY-Ring road Utara-Kampus Amikom";
cout<<endl;
}
else if(jalurbus == 9)
{
cout << "Jalur Bus 9 : RS.Bethesda-Jl.Sagan-RS.Panti Rapih";
cout<<endl;
}
else if(jalurbus == 10)
{
cout << "Jalur Bus 10 : Kridosono-Gramedia-UGM";
cout<<endl;
}
else if(jalurbus == 11)
{
cout << "Jalur Bus 11 : Jl.C.Simanjutak-Jl.Kaliurang-RS.Sardjito";
cout<<endl;
}
else if(jalurbus == 12)
{
cout << "Jalur Bus 12 : SMA N 3 Yogyakarta-Gramedia-Mirota Kampus";
cout<<endl;
}
else if(jalurbus == 13)
{
cout << "Jalur Bus 13 : Jl.Pramuka-Jl.Dr.Soepomo-Jl.Kapas";\
cout<<endl;
}
else if(jalurbus == 14)
{
cout << "Jalur Bus 14 : kampus UIN-Ambarokmo Plaza-Jl.Solo";
cout<<endl;
}
else if(jalurbus == 15)
{
cout << "Jalur Bus 15 : Jl.Kusumaegara-Halte Senopati-Taman Budaya Jogja";
cout<<endl;
}
else if(jalurbus == 16)
{
cout << "Jalur Bus 16 : Jl.Kusumaegara-Taman Siswa-Rumah Sakit Jogja Wirosaban";
cout<<endl;
}
else if(jalurbus == 17)
{
cout << "Jalur Bus 17 : UIN-Galeria Mall-Masjid UGM";
cout<<endl;
}
else if(jalurbus == 18)
{
cout << "Jalur Bus 18 : PGSD USD-Ring Road Utara-Monjali";
cout<<endl;
}
else if(jalurbus == 19)
{
cout << "Jalur Bus 19 : Jalan Kaliurang-Taman Lampion-Taman Sleman";
cout<<endl;
}
else if(jalurbus == 20)
{
cout << "Jalur Bus 20 : Jalan Kaliurang-Jalan Magelang-Borobudur";
cout<<endl;
}
else
{
cout << "Jalur Bus Tidak Tersedia";
}
}
if (jam==1){gotoxy(20,81);cout<<"Pukul : 06.00";
}
else if (jam==2){gotoxy(20,81);cout<<"Pukul : 07.15";
}
else if(jam==3){gotoxy(20,81);cout<<"Pukul : 07.40";
}
else if(jam==4){gotoxy(20,81);cout<<"Pukul : 08.00";
}
else if(jam==5){gotoxy(20,81);cout<<"Pukul : 09.00";
}
else if(jam==6){gotoxy(20,81);cout<<"Pukul : 09.30";
}
else if (jam==7){gotoxy(20,81);cout<<"Pukul : 10.00";
}
else if (jam==8){gotoxy(20,81);cout<<"Pukul : 10.30";
}
else if (jam==9){gotoxy(20,81);cout<<"Pukul : 10.45";
}
else if (jam==10){gotoxy(20,81);cout<<"Pukul : 11.30";
}
else if (jam==11){gotoxy(20,81);cout<<"Pukul : 12.30";
}
else if (jam==12){gotoxy(20,81);cout<<"Pukul : 14.30";
}
else if (jam==13){gotoxy(20,81);cout<<"Pukul : 15.00";
}
else if (jam==14){gotoxy(20,81);cout<<"Pukul : 15.30";
}
else if (jam==15){gotoxy(20,81);cout<<"Pukul : 15.45";
}
else if (jam==16){gotoxy(20,81);cout<<"Pukul : 16.30";
}
else if (jam==17){gotoxy(20,81);cout<<"Pukul : 16.45";
}
else if (jam==18){gotoxy(20,81);cout<<"Pukul : 17.00";
}
else if (jam==19){gotoxy(20,81);cout<<"Pukul : 17.30";
}
else if (jam==20){gotoxy(20,81);cout<<"Pukul : 18.00";
}
else if (jam==21){gotoxy(20,81);cout<<"Pukul : 18.30";
}
else{cout<<endl;
gotoxy(20,81);
cout<<"Pilihan waktu tidak teredia";
}
int a;
gotoxy(20,84);
cout<<"+++++++++++++++++++++++++++++++++++";
gotoxy(20,85);
cout<<"|| 1.Cetak ||"<<endl;
gotoxy(20,86);
cout<<"|| 2.Kembali ke Menu Untuk Hapus ||"<<endl;
gotoxy(20,87);
cout<<"+++++++++++++++++++++++++++++++++++";
cout<<endl;
cin>>a;
if(a==1){
system("cls");
print();
}
else{Menu();}
}
void EnqueueBus :: print()
{ gotoxy(23,3);
cout<<"Nama : "<<nama;
gotoxy(23,4);
cout<<"No Telepon : "<<nomer;
cout<<endl;
if(kosong()==0)
{
for(int i = ekor;i>=kepala;i--)
{
if(bus[i] == 1)
{
gotoxy(23,5);
cout << "Jalur 1 : Glagah-Kusumanegara-Malioboro-Kaliurang\n" ;
}
else if(bus[i] == 2)
{
gotoxy(23,5);
cout << "Jalur 2 : Jl.Pramuka-Umbulharjo-Veteran-Gejayan\n";
}
else if(bus[i] == 3)
{
gotoxy(23,5);
cout << "Jalur 3 : CondongCatur-BabarSari-Janti-Kusumanegara\n";
}
else if(bus[i] == 4)
{
gotoxy(23,5);
cout << "Jalur 4 : Gejayan-UGM-BulakSumur-KaliUrang\n";
}
else if(bus[i] == 5)
{
gotoxy(23,5);
cout << "Jalur Bus 5 : Jl.Kusumanegara-Gembira loka-Jogja Expo Center\n";
}
else if(bus[i] == 6)
{
gotoxy(23,5);
cout << "Jalur Bus 6 : Pasar Kembang-Malioboro-Taman Pintar\n";
}
else if(bus[i] == 7)
{
gotoxy(23,5);
cout << "Jalur Bus 7 : Alun-alun Utara -Pasar Ngasem-Wirobrajan\n";
}
else if(bus[i] == 8)
{
gotoxy(23,5);
cout << "Jalur Bus 8 : Jl.Sagan-UNY-Ring road Utara-Kampus Amikom\n";
}
else if(bus[i] == 9)
{
gotoxy(23,5);
cout << "Jalur Bus 9 : RS.Bethesda-Jl.Sagan-RS.Panti Rapih\n";
}
else if(bus[i] == 10)
{
gotoxy(23,5);
cout << "Jalur Bus 10 : Kridosono-Gramedia-UGM\n";
}
else if(bus[i] == 11)
{
gotoxy(23,5);
cout << "Jalur Bus 11 : Jl.C.Simanjutak-Jl.Kaliurang-RS.Sardjito\n";
}
else if(bus[i] == 12)
{
gotoxy(23,5);
cout << "Jalur Bus 12 : SMA N 3 Yogyakarta-Gramedia-Mirota Kampus\n";
}
else if(bus[i] == 13)
{
gotoxy(23,5);
cout << "Jalur Bus 13 : Jl.Pramuka-Jl.Dr.Soepomo-Jl.Kapas\n";
}
else if(bus[i] == 14)
{
gotoxy(23,5);
cout << "Jalur Bus 14 : kampus UIN-Ambarokmo Plaza-Jl.Solo\n";
}
else if(bus[i] == 15)
{
gotoxy(23,5);
cout << "Jalur Bus 15 : Jl.Kusumaegara-Halte Senopati-Taman Budaya Jogja\n";
}
else if(bus[i] == 16)
{
gotoxy(23,5);
cout << "Jalur Bus 16 : Jl.Kusumaegara-Taman Siswa-Rumah Sakit Jogja Wirosaban\n";
}
else if(bus[i] == 17)
{
gotoxy(23,5);
cout << "Jalur Bus 17 : UIN-Galeria Mall-Masjid UGM\n";
}
else if(bus[i] == 18)
{
gotoxy(23,5);
cout << "Jalur Bus 18 : PGSD USD-Ring Road Utara-Monjali\n";
}
else if(bus[i] == 19)
{
gotoxy(23,5);
cout << "Jalur Bus 19 : Jalan Kaliurang-Taman Lampion-Taman Sleman\n";
}
else if(bus[i] == 20)
{
gotoxy(23,5);
cout << "Jalur Bus 20 : Jalan Kaliurang-Jalan Magelang-Borobudur\n";
}
else
{
gotoxy(23,5);
cout << "Antrian Bus Masih Kosong" << endl;
}
}
}
if (jam==1){gotoxy(23,6);
cout<<"Waktu berangkat : 06.00";
}
else if (jam==2){gotoxy(23,6);
cout<<"Waktu berangkat : 07.15";
}
else if (jam==3){gotoxy(23,6);
cout<<"Waktu berangkat : 07.40";
}
else if (jam==4){gotoxy(23,6);
cout<<"Waktu berangkat : 08.00";
}
else if (jam==5){gotoxy(23,6);
cout<<"Waktu berangkat : 09.00";
}
else if (jam==6){gotoxy(23,6);
cout<<"Waktu berangkat : 09.30";
}
else if (jam==7){gotoxy(23,6);
cout<<"Waktu berangkat : 10.00";
}
else if (jam==8){gotoxy(23,6);
cout<<"Waktu berangkat : 10.30";
}
else if (jam==9){gotoxy(23,6);
cout<<"Waktu berangkat : 10.45";
}
else if (jam==10){gotoxy(23,6);
cout<<"Waktu berangkat : 11.30";
}
else if (jam==11){gotoxy(23,6);
cout<<"Waktu berangkat : 12.30";
}
else if (jam==12){gotoxy(23,6);
cout<<"Waktu berangkat : 14.30";
}
else if (jam==13){gotoxy(23,6);
cout<<"Waktu berangkat : 15.00";
}
else if (jam==14){gotoxy(23,6);
cout<<"Waktu berangkat : 15.30";
}
else if (jam==15){gotoxy(23,6);
cout<<"Waktu berangkat : 15.45";
}
else if (jam==16){gotoxy(23,6);
cout<<"Waktu berangkat : 16.30";
}
else if (jam==17){gotoxy(23,6);
cout<<"Waktu berangkat : 16.45";
}
else if (jam==18){gotoxy(23,6);
cout<<"Waktu berangkat : 17.00";
}
else if (jam==19){gotoxy(23,6);
cout<<"Waktu berangkat : 17.30";
}
else if (jam==20){gotoxy(23,6);
cout<<"Waktu berangkat : 18.00";
}
else if (jam==21){gotoxy(23,6);
cout<<"Waktu berangkat : 18.30";
}
else{gotoxy(23,6);
cout<<"Pilihan waktu tidak teredia";
}
}
void EnqueueBus :: header()
{
gotoxy( 2, 1 );
for ( int i = 1; i < 79; i++ )
{
cout << char( 205 );
}
gotoxy( 1, 1 );
cout << char( 201 );
gotoxy( 80, 1 );
cout << char( 187 );
for ( int i = 2; i < 25; i++ )
{
gotoxy( 1, i );
cout << char( 186 );
}
gotoxy( 1, 25 );
cout << char( 200 );
gotoxy( 80, 25 );
cout << char( 188 );
for ( int i = 2; i < 25; i++ )
{
gotoxy( 80, i );
cout << char( 186 );
}
gotoxy( 2, 25 );
for ( int i = 1; i < 79; i++ )
{
cout << char( 205 );
}
//bingkai beetwen list of main menu
gotoxy( 24, 6 );
for ( int i = 1; i < 39; i++ )
{
cout << char( 205 );
}
gotoxy( 23, 6 );
cout << char( 201 );
gotoxy( 62, 6 );
cout << char( 187 );
for ( int i = 7; i < 16; i++ )
{
gotoxy( 23, i );
cout << char( 186 );
}
gotoxy( 23, 16 );
cout << char( 200 );
gotoxy( 24, 16 );
for ( int i = 1; i < 39; i++ )
{
cout << char( 205 );
}
gotoxy( 62, 16 );
cout << char( 188 );
for ( int i = 7; i < 16; i++ )
{
gotoxy( 62, i );
cout << char( 186 );
}
}
void EnqueueBus :: Menu()
{
int jalurbus;
for ( ; ; )
{
system("cls");
system("color f");
header();
gotoxy( 28, 8 );
cout<< "SIMULASI PEMILIHAN JALUR BUS";
char pilihan;
gotoxy(58,21);
cout<< "Made By : ";
gotoxy(58,23);
cout<< "Amallia Istikhomah";
gotoxy(58,24);
cout<< "Listy Ismiatun";
gotoxy( 35, 9 );
cout<< "1. Jalur Bus" ;
gotoxy( 35, 10 );
cout<< "2. Hapus Semua" ;
gotoxy( 25, 15 );
cout<< "Enter your choice : " ;
gotoxy( 48, 15 );
cin >> pilihan;
system("cls");
switch ( pilihan )
{
case '1':
awal:
system("cls");
cout<<" ||3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3||"<<endl<<endl;
cout <<" || Jalur 1 : Glagah-Kusumanegara-Malioboro-Kaliurang ||" ;
cout<<endl<<endl;
cout <<" || Jalur 2 : Jl.Pramuka-Umbulharjo-Veteran-Gejayan ||";
cout<<endl<<endl;
cout << " || Jalur 3 : CondongCatur-BabarSari-Janti-Kusumanegara ||";
cout<<endl<<endl;
cout << " || Jalur 4 : Gejayan-UGM-BulakSumur-KaliUrang ||";
cout<<endl<<endl;
cout << " || Jalur 5 : Jl.Kusumanegara-Gembira loka-Jogja Expo Center ||";
cout<<endl<<endl;
cout << " || Jalur 6 : Pasar Kembang-Malioboro-Taman Pintar ||";
cout<<endl<<endl;
cout << " || Jalur 7 : Alun-alun Utara -Pasar Ngasem-Wirobrajan ||";
cout<<endl<<endl;
cout << " || Jalur 8 : Jl.Sagan-UNY-Ring road Utara-Kampus Amikom ||";
cout<<endl<<endl;
cout << " || Jalur 9 : RS.Bethesda-Jl.Sagan-RS.Panti Rapih ||";
cout<<endl<<endl;
cout << " || Jalur 10 : Kridosono-Gramedia-UGM ||";
cout<<endl<<endl;
cout << " || Jalur 11 : Jl.C.Simanjutak-Jl.Kaliurang-RS.Sardjito ||";
cout<<endl<<endl;
cout << " || Jalur 12 : SMA N 3 Yogyakarta-Gramedia-Mirota Kampus ||";
cout<<endl<<endl;
cout << " || Jalur 13 : Jl.Pramuka-Jl.Dr.Soepomo-Jl.Kapas ||";
cout<<endl<<endl;
cout << " || Jalur 14 : kampus UIN-Ambarokmo Plaza-Jl.Solo ||";
cout<<endl<<endl;
cout << " || Jalur 15 : Jl.Kusumaegara-Halte Senopati-Taman Budaya Jogja ||";
cout<<endl<<endl;
cout << " || Jalur 16 : Jl.Kusumaegara-Taman Siswa-Rumah Sakit Jogja Wirosaban ||";
cout<<endl<<endl;
cout << " || Jalur 17 : UIN-Galeria Mall-Masjid UGM ||";
cout<<endl<<endl;
cout << " || Jalur 18 : PGSD USD-Ring Road Utara-Monjali ||";
cout<<endl<<endl;
cout << " || Jalur 19 : Jalan Kaliurang-Taman Lampion-Taman Sleman ||";
cout<<endl<<endl;
cout << " || Jalur 20 : Jalan Kaliurang-Jalan Magelang-Borobudur ||";
cout<<endl<<endl;
cout<<" ||3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3/3||";
cout<<endl<<endl;
gotoxy(25,45);
cout<<"=========================="<<endl;
gotoxy(25,46);
cout<<"|| Jadwal Berangkat Bus ||"<<endl;
gotoxy(25,47);
cout<<"=========================="<<endl;
gotoxy(25,48);
cout<<"|| No || Pukul ||"<<endl;
gotoxy(25,49);
cout<<"=========================="<<endl;
gotoxy(25,50);
cout<<"|| 1 || 06.00 ||"<<endl;
gotoxy(25,51);
cout<<"|| 2 || 07.15 ||"<<endl;
gotoxy(25,52);
cout<<"|| 3 || 07.40 ||"<<endl;
gotoxy(25,53);
cout<<"|| 4 || 08.00 ||"<<endl;
gotoxy(25,54);
cout<<"|| 5 || 09.00 ||"<<endl;
gotoxy(25,55);
cout<<"|| 6 || 09.30 ||"<<endl;
gotoxy(25,56);
cout<<"|| 7 || 10.00 ||"<<endl;
gotoxy(25,57);
cout<<"|| 8 || 10.30 ||"<<endl;
gotoxy(25,58);
cout<<"|| 9 || 10.40 ||"<<endl;
gotoxy(25,59);
cout<<"|| 10 || 11.30 ||"<<endl;
gotoxy(25,60);
cout<<"|| 11 || 12.30 ||"<<endl;
gotoxy(25,61);
cout<<"|| 12 || 14.30 ||"<<endl;
gotoxy(25,62);
cout<<"|| 13 || 15.00 ||"<<endl;
gotoxy(25,63);
cout<<"|| 14 || 15.30 ||"<<endl;
gotoxy(25,64);
cout<<"|| 15 || 15.45 ||"<<endl;
gotoxy(25,65);
cout<<"|| 16 || 16.30 ||"<<endl;
gotoxy(25,66);
cout<<"|| 17 || 16.45 ||"<<endl;
gotoxy(25,67);
cout<<"|| 18 || 17.00 ||"<<endl;
gotoxy(25,68);
cout<<"|| 19 || 17.30 ||"<<endl;
gotoxy(25,69);
cout<<"|| 20 || 18.00 ||"<<endl;
gotoxy(25,70);
cout<<"|| 21 || 18.30 ||"<<endl;
gotoxy(25,71);
cout<<"=========================="<<endl;
gotoxy(20,75);
cout<< "Nama Anda : ";
cin>>nama;
gotoxy(20,76);
cout<< "No Telepon : ";
cin>>nomer;
gotoxy(20,77);
cout<< "Masukkan No Jalur Bus : ";
cin >> jalurbus;
gotoxy(20,78);
cout<<"Masukkan Waktu yang Anda Pilih : ";
cin>>jam;
ulang:
char pil;
//system("cls");
gotoxy(20,80);
cout<<"Yakin (y / t) : ";
cin>>pil;
gotoxy(20,81);
if(pil=='y' || pil=='Y'){
gotoxy(20,82);
busMasuk( jalurbus);
}
else if(pil=='t' || pil=='T'){
goto awal;
}
else{
goto ulang;}
break;
case '2':
hapusSemuaAntrian();
break;
default:
gotoxy( 30, 12 ); cout<< "Your Choice is not Available" ; getche();
}
getche();
}
}
int main()
{
EnqueueBus a;
}