-
Notifications
You must be signed in to change notification settings - Fork 2
/
catalogue.cpp
50 lines (49 loc) · 1.25 KB
/
catalogue.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#include<bits/stdc++.h>
#include<fstream>
#include"catalogue.h"
#include"product.h"
#include"clothes.h"
#include"books.h"
#include"watches.h"
namespace sample
{
void catalogue::show_catalogue()
{
char h;
do
{
cout<<"************************* LIST OF ITEMS TO BUY *************************\n";
cout<<"1.CLOTHES\n";
cout<<"2.BOOKS\n";
cout<<"3.WATCHES\n";
cout<<"ENTER YOUR CHOICE : ";
int choice;
cin>>choice;
system("clear");
if(choice==1)
{
clothes obj;
obj.show_menu();
}
else if(choice==2)
{
books obj;
obj.show_menu();
}
else if(choice==3)
{
watches obj;
obj.show_menu();
}
else
{
cout<<'\a';
cout<<"Sorry Invalid Input :(\n";
cout<<"Press d to try again and any other key to quit\n";
cin>>h;
system("clear");
}
}
while(h=='d'|| h=='D');
}
}