2 Write Program Uses Capabilities Shelved Objects Program Maintain Telephone Database Comm Q37240163

2. Write a program which uses the capabilities of shelvedobjects. The program will maintain a telephone database. Thecommands to use the database are as follows:

 ‘whois phone-number’ Find the information associated with aphone number

 ‘add phone-number information’ Add information to a phonenumber listing in the database

 ‘search keyword’ Find all entries which include keyword.

 ‘quit’ Exit the application.

 some valid commands:

a) add 2162215680 Fred Smith

b) add 2063607788 Roberta Flores

c) quit

 subsequent sessions might be:

a) whois 2162215680

b) search Flores

c) search fred

d) add 2162215680 Owes me $50.

e) Quit

 commands are read in as strings and the line is parsed intocommand and arguments

, :Python32 python.exe telefonedb.py cscCSenesters CSCT 15111ProjectsTel onmands are whols, add, searchand quit onmand: add

,

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.