Created
November 25, 2011 18:46
-
-
Save atmb4u/1394169 to your computer and use it in GitHub Desktop.
Another self modifying system which gets modified each timw someone accesses ut
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
f = open("choice.py","r+") | |
i = 1###########This Number will get replaced | |
print "%s times" % (i) | |
f.seek(41) | |
c = f.readline() | |
m = re.match('\d+',c) | |
f.seek(41) | |
f.write(str(int(m.group())+1)) | |
f.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment