Codes for Interactive programming in Python