#include<iostream>
using namespace std;
void intro();
void menu()
{
cout<<"****************************************"<<endl;
cout<<"press 1 for enter riksha in parking:"<<endl;
cout<<endl;
cout<<"press 2 for enter car in parking:"<<endl;
cout<<endl;
cout<<"press 3 for enter truck in parking:"<<endl;
cout<<endl;
cout<<"press 4 for enter bike in parking:"<<endl;
cout<<endl;
cout<<"press 5 for display the all data:"<<endl;
cout<<"***************************************"<<endl;
}
int main()
{
int choice;
int count=0,amount=0;
int r=0,c=0,t=0,b=0;
cout<<"\t\t\t\t\t$$$$$$$$$$$$$$$$$$$$$$$$$$"<<endl;
cout<<"\t\t\t\t\tparking management system:"<<endl;
cout<<"\t\t\t\t\t$$$$$$$$$$$$$$$$$$$$$$$$$$"<<endl;
cout<<endl<<endl;
void intro();
while(true)
{
menu();
cin>>choice;
if(choice==1)
{
if(count<=10)
{
count=count+1;
amount=amount+100;
r++;
}
else
cout<<"parking full:"<<endl;
}
else if(choice==2)
{
if(count<=10)
{
count=count+1;
amount=amount+200;
c++;
}
else
cout<<"parking full"<<endl;
}
else if(choice==3)
{
if(count<=10)
{
count=count+1;
amount=amount+300;
t++;
}
else
cout<<"parking full"<<endl;
}
else if(choice==4)
{
if(count<=10)
{
count=count+1;
amount=amount+50;
b++;
}
else
cout<<"parking full"<<endl;
}
else if(choice==5)
{
cout<<"#######################################"<<endl;
cout<<"the totle number of veicles are:"<<count<<endl;
cout<<"the totle amount is:"<<amount<<endl;
cout<<"the totle number of rikshas in parking:"<<r<<endl;
cout<<"the totle number of cars in parking:"<<c<<endl;
cout<<"the totle number of trucks in parking:"<<t<<endl;
cout<<"the totle number of bikes in parking:"<<b<<endl;
cout<<"########################################"<<endl;
}
else
{
cout<<"invalied number:";
}
}
}
void intro()
{
cout<<"\t\t\n\nmade by:::hamza rehman"<<endl;
cout<<"\t\t\n\nuniversity:::ABASYN"<<endl;
}
No comments:
Post a Comment