mirage:MultiList raj$ python3 Database.py data
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: ps

(s12,Jones) Supplies: (p1,5) (p2,4) 
(s21,Smith) Supplies: (p1,4) (p2,3) (p3,8) 
(s30,Blake) Supplies: 
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: pp

(p1,nut) Supplied by: (s12,5) (s21,4) 
(p2,bolt) Supplied by: (s12,4) (s21,3) 
(p3,wheel) Supplied by: (s21,8) 
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: fsgp p2

(s12,Jones,4)
(s21,Smith,3)

*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: fpgs s21

(p1,nut,4)
(p2,bolt,3)
(p3,wheel,8)

*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: fcsgp p1


Cheapest suppliers:
('s21', 'Smith', 4)
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: is s44:tony
Supplier s44 has been inserted
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: ip p5:camshaft
Part p5 has been inserted
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: isp s12:p5:22
Supply Element s12, p5 has been inserted
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: isp s12:p5:55
Supply Element s12, p5 was NOT inserted
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: pp

(p1,nut) Supplied by: (s12,5) (s21,4) 
(p2,bolt) Supplied by: (s12,4) (s21,3) 
(p3,wheel) Supplied by: (s21,8) 
(p5,camshaft) Supplied by: (s12,22) 
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: isp s21:p5:55
Supply Element s21, p5 has been inserted
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: pp

(p1,nut) Supplied by: (s12,5) (s21,4) 
(p2,bolt) Supplied by: (s12,4) (s21,3) 
(p3,wheel) Supplied by: (s21,8) 
(p5,camshaft) Supplied by: (s12,22) (s21,55) 
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: ps

(s12,Jones) Supplies: (p1,5) (p2,4) (p5,22) 
(s21,Smith) Supplies: (p1,4) (p2,3) (p3,8) (p5,55) 
(s30,Blake) Supplies: 
(s44,tony) Supplies: 
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: dsp s12:p1
Supply Element s12, p1 has been deleted
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: ps

(s12,Jones) Supplies: (p2,4) (p5,22) 
(s21,Smith) Supplies: (p1,4) (p2,3) (p3,8) (p5,55) 
(s30,Blake) Supplies: 
(s44,tony) Supplies: 
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: usp s21:p1:400
Supply Element s21, p1 has been updated
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: ps

(s12,Jones) Supplies: (p2,4) (p5,22) 
(s21,Smith) Supplies: (p1,400) (p2,3) (p3,8) (p5,55) 
(s30,Blake) Supplies: 
(s44,tony) Supplies: 
*********************************************
Menu of Options:

ps (print suppliers)
pp (print parts)
fsgp pno (find suppliers given part)
fpgs sno (find parts given supplier)
fcsgp pno (find cheapest suppliers given part)

is sno:sname (insert supplier)
ds sno (delete supplier)
us sno:sname (update supplier name)

ip pno:pname (insert part)
dp pno (delete part)
up pno:pname (update part name)

isp sno:pno:price (insert supply)
dsp sno:pno (delete supply)
usp sno:pno:price (update supply price)

q (quit)

Your option: q
Bye!

mirage:MultiList raj$