re.py
author Christian Urban <christian dot urban at kcl dot ac dot uk>
Tue, 11 Dec 2012 11:07:49 +0000
changeset 89 24adcc265f2e
parent 49 d2c6852ca8da
permissions -rwxr-xr-x
typo

#!/usr/bin/env python
import re
import sys

cn = sys.argv[1]

r1 = '((a?){%s})' % cn
r2 = 'a{%s}' % cn

m = re.match(r1 + r2 , "a" * int(cn)) 

print m.group(0)