changeset 558 | 447ed6c7cdad |
parent 420 | 25bc57b32efa |
child 613 | bfd511b7ecbf |
--- a/progs/catastrophic.py Sun Sep 23 09:04:24 2018 +0100 +++ b/progs/catastrophic.py Mon Sep 24 11:05:39 2018 +0100 @@ -2,15 +2,26 @@ import re import sys -# case of catastrophic backtracking in Python +# A case of catastrophic backtracking in Python # # regex: (a?){n} a{n} # strings: aa... # +# call with: +# +# > ./catastrophic.py 20 +# +# or +# +# > ./catastrophic.py 28 +# +# # call with timing as: # # > time ./catastrophic.py 20 + + # counter n given on the command line cn = sys.argv[1]