Google Interview Question

code python architecture of db mapping.