3 ms·
Well here's a starter for you. Using enhanced regex syntax you can match a language containing strings of prime length. On the other hand (using the pumping l
by tome 18y ago
Well here's a starter for you. Using enhanced regex syntax you can match a language containing strings of prime length. On the other hand (using the pumping lemma[1]) you can prove that that set is not regular, hence not detectable by a standard regex.
[1] http://books.google.com/books?id=MDQ_K7-z2AMC&pg=PA47&lpg=PA47&dq=finite+automaton+prime&source=bl&ots=0wWTv5AeBd&sig=6sOwOf6PNdQmcvI6QhWVMKLvKKA&hl=en&sa=X&oi=book_result&resnum=3&ct=result http://books.google.com/books?id=MDQ_K7-z2AMC&pg=PA47...
- llimllib 18y agoSipser's book is great for understanding this stuff, IMHO: http://books.google.com/books?id=eRYFAAAACAAJ&dq=sipser+theory&ei=SvqKSfnBHZb0ygS22KG6BQ http://books.google.com/books?id=eRYFAAAACAAJ&dq=sipser+...