• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Inverse Regex Library?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Inverse Regex Library?


  • Subject: Re: Inverse Regex Library?
  • From: Philip Mötteli <email@hidden>
  • Date: Thu, 17 Jul 2008 20:34:04 +0200

Hi,


Thanks for all the answers.


Surely the following sequence of words would produce Word[1-9]{1,2} instead of Word[0-9]{1,2} because there is no representative 0 in the sample ?

 "Word1"
"Word2"
"Word5"
"Word8"
"Word11"
"Word19"
"Word23"
"Word45"
"Word77"

how
will the computer know that it should convert the list into Word[0-9] {1,2}
instead of Word[1,2,5,8,4,7][1,9,3,5,7]?"

Don't think a reliable solution for this can exist. It's just too few information to detect the right pattern.
Even as a human being I'm actually not even 75% sure what's the right pattern for these words. How should a computer then?

I'm actually in a lucky position, because

1. The strings are not complicated at all.
2. I don't need the right solution – just ONE solution.
3. If it is the wrong solution, I use it as long as it works and then I restart the search for the next solution. I will end up with a solution, that satisfies all cases.


So does anybody know of a library, that would just come up with one solution? I heard of Grail+, but…


Thanks Phil

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Inverse Regex Library?
      • From: Andy Lee <email@hidden>
References: 
 >Re: Inverse Regex Library? (From: Erik Buck <email@hidden>)

  • Prev by Date: Re: How to programmatically open an NSComboBox's list?
  • Next by Date: Re: Handling key equivalents in a controller class?
  • Previous by thread: Re: Inverse Regex Library?
  • Next by thread: Re: Inverse Regex Library?
  • Index(es):
    • Date
    • Thread