I have been stuck for months trying to edit the python interpreter (from www.python.org). All I want to do is to change the keywords eg. change from. English language: print() to Ibo language de().
I have been stuck for months trying to edit the python interpreter (from www.python.org). All I want to do is to change the keywords eg. change from. English language: print() to Ibo language de().
Use regular expressions in another script to parse your main script:
import reold = open('main.py')
data = old.read()
old.close()data = re.sub(r'\bde\b', 'print', data)
# continue to replace other keywordsnew = open('main.py', 'w')
new.write(data)
new.close()