(.+|)foo(.+|) Lol so awesome this. I oblige. Much love!
Powers: ^((((((((((x)\10?)\9?)\8?)\7?)\6?)\5?)\4?)\3?)\2?)\1?$ I feel like there's gotta be a sneakier way of doing this.
^x{32}$|^(x{2}){1,8}$|^(x{64})+$|^x$71–80 of 189 posts
Does anybody know how to do math with regex? (triples) And conditionals don't seem to work?
Earlier quoted context omitted.
The goal in code golf is lower character count, not lower score - which is also the case here.
Therefore, the score it provides should be a running tally of how many characters you've used to make it match the scoring system of golf; which is the lowest number of strokes wins. The scoring system for this is incremental which is the opposite of golf. A proper scoring system with this would provide a character limit (par) for each section and the goal would be to write a shorter regex formula to complete the tas…
The title was (most probably) derived from Code Golf, which is a competition in coding something with as few characers as possible. Code Golf was derived from Golf, where you want to use as few turns as possible.
The score going up and not down, which is done because you get more points the more objectives you fulfill, does not change the objective of this game or what it is based on.
^(?!(..+)(\1)+$)
Why does that work on primes? I got it by mistake when fiddling with the parenthesis locations but I was expecting to have to deal with xx separately.Earlier quoted context omitted.
Therefore, the score it provides should be a running tally of how many characters you've used to make it match the scoring system of golf; which is the lowest number of strokes wins. The scoring system for this is incremental which is the opposite of golf. A proper scoring system with this would provide a character limit (par) for each section and the goal would be to write a shorter regex formula to complete the tas…
I don't get what this is all about. The title was (most probably) derived from Code Golf, which is a competition in coding something with as few characers as possible. Code Golf was derived from Golf, where you want to use as few turns as possible. The score going up and not down, which is done because you get more points the more objectives you fulfill, does not change the objective of this game or what it is based…
Golf scoring penalizes you with more "points" by how many strokes you take.
If you are playing a Par 4 and it takes you 6 swings to get in the cup you just got _penalized_ +2
If your partner gets in the cup in 2 swings he is awarded -2
Therefor "Regex Golf" has its scoring reversed
Many times I would match the exact opposite opposite of what I wanted. Is there a general rule for inverting regexps? ^ and ?! don't seem general purpose.
I have the most trouble with regex, and something about seeing my matches as I type made this incredibly useful for me!
http://regexpal.com/ or for a paid desktop program http://www.regexbuddy.com/ , which is most excellent