Database Python

import shelve
s = shelve.open('data')
s['key'] = range(4)
print s['key']               
s['key'].append('more')       
print s['key']                    
x = s['key']              
x.append('more')       
s['key'] = x              
print s['key']