One last question on this topic..

I'd like to call the files and the string form the command line like

Python whatever.py STRINGTOSEARCH NEWFILE FILETOOPEN

My understanding is that it would be accomplished as such

import sys

myString = sys.argv[1]
filetoopen = sys.argv[2]
newfile = sys.argv[3]


ETC ETC CODE HERE

Is this correct/pythonic? Is there a more recommended way? Am I retarded?

Thanks again in advance,
Scott
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to