Write a program to find last insert ID.

import MySQLdb

db = MySQLdb.connect(import MySQLdb

db = MySQLdb.connect(‘localhost’,’username’,’pasword’,’databsename’)
curs = db.cursor()

p = ‘LAST_INSERT_ID()’
pk = curs.execute(p)

print pk