Hello

        I've been reading tutorials on regexes in Python, but I still
don't get it:

========
#!/usr/bin/python

#myscript.py 0123456789

import sys,re

#Turn 0123456789 into 01.23.45.67.89
p = re.compile('(\d\d)(\d\d)(\d\d)(\d\d)(\d\d)')
phone = p.sub('\1.\2.\3.\4.\5',sys.argv[1])
print phone
========

=> Python displays "...." instead. Any idea what I'm doing wrong?

Thank you.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to