Python - Code snippet not working on Python 2.5.6, using IDLE
- by Francisco P.
Hello, everyone
I am using a piece of self-modifying code for a college project.
Here it is:
import datetime
import inspect
import re
import sys
def main():
# print the time it is last run
lastrun = 'Mon Jun 8 16:31:27 2009'
print "This program was last run at ",
print lastrun
# read in the source code of itself
…