Exercise: Phone book in JSON


Write a script that acts as a phonebook. As "database" use a file in JSON format.


$ python phone.py Foo 123
Foo added

$ python phone.py Bar
Bar is not in the phnebook

$ python phone.py Bar 456
Bar added

$ python phone.py Bar
456

$ python phone.py Foo
123