Login with username, password and session length

News:

Steam group. Have any of you ever noticed that the old group name was misspelled?

Author Topic: ^.* Tycoon( [0-9]+)?  (Read 432 times)

  • Banned Virally Yours
  • Administrator
  • I don't shower
  • ******
  • Posts: 2067
  • I want to be a scientist.
    • MSN Messenger - chrisinajar@gmail.com
    • AOL Instant Messenger - chrisinajar
    • Yahoo Instant Messenger - chrisinajar
    • View Profile
    • The People's Republic of Shenanigans
    • Email
^.* Tycoon( [0-9]+)?
« on: April 05, 2009, 10:01:39 am »
They're all awesome for exactly one day. Last night I played lemonade Tycoon until 4am, where I was making more than 1,000 a day...

  • Shen's Macro
  • ***
  • Posts: 451
    • MSN Messenger - blargh@gmail.com
    • View Profile
    • http://jentou.com
    • Email
Re: ^.* Tycoon( [0-9]+)?
« Reply #1 on: April 05, 2009, 02:45:29 pm »
I loved the roller coaster tycoon series. Played those for so long.

By the way, I like the regular expression you have there.

  • Banned Virally Yours
  • Administrator
  • I don't shower
  • ******
  • Posts: 2067
  • I want to be a scientist.
    • MSN Messenger - chrisinajar@gmail.com
    • AOL Instant Messenger - chrisinajar
    • Yahoo Instant Messenger - chrisinajar
    • View Profile
    • The People's Republic of Shenanigans
    • Email
Re: ^.* Tycoon( [0-9]+)?
« Reply #2 on: April 05, 2009, 10:26:50 pm »
Well, I needed to match all of them. I figured it was the most effective way to do it.

  • Shen's One
  • *
  • Posts: 83
    • View Profile
    • Email
Re: ^.* Tycoon( [0-9]+)?
« Reply #3 on: April 16, 2009, 10:35:35 am »
what if you changed the last part from
Code: [Select]
([0-9]+)?
to
Code: [Select]
{0-9]*
That should match zero or more numbers to handle sim-magnitude numbers of sequals.

  • Banned Virally Yours
  • Administrator
  • I don't shower
  • ******
  • Posts: 2067
  • I want to be a scientist.
    • MSN Messenger - chrisinajar@gmail.com
    • AOL Instant Messenger - chrisinajar
    • Yahoo Instant Messenger - chrisinajar
    • View Profile
    • The People's Republic of Shenanigans
    • Email
Re: ^.* Tycoon( [0-9]+)?
« Reply #4 on: April 16, 2009, 01:45:52 pm »
what if you changed the last part from
Code: [Select]
([0-9]+)?
to
Code: [Select]
{0-9]*
That should match zero or more numbers to handle sim-magnitude numbers of sequals.
Correct, but not what I was going for. I needed the space to be optional in addition to the numbers, (also you did a { instead of a [) You're method would result in
Code: [Select]
^.* Tycoon ?[0-9]*which I like less. Also, + matches 1 or more, so it would also match the high magnitude sequels.

  • Shen's One
  • *
  • Posts: 83
    • View Profile
    • Email
Re: ^.* Tycoon( [0-9]+)?
« Reply #5 on: April 16, 2009, 04:52:24 pm »
Yep, I had forgotten the space. You need to use a * rather than a + to handle games without a sequel number after them. Like Rollercoaster Tycoon.

thread successfully derailed!

  • Banned Virally Yours
  • Administrator
  • I don't shower
  • ******
  • Posts: 2067
  • I want to be a scientist.
    • MSN Messenger - chrisinajar@gmail.com
    • AOL Instant Messenger - chrisinajar
    • Yahoo Instant Messenger - chrisinajar
    • View Profile
    • The People's Republic of Shenanigans
    • Email
Re: ^.* Tycoon( [0-9]+)?
« Reply #6 on: April 16, 2009, 11:43:26 pm »
Yep, I had forgotten the space. You need to use a * rather than a + to handle games without a sequel number after them. Like Rollercoaster Tycoon.

thread successfully derailed!
No, because the question mark, making the previous item optional, is after the parenthesis making the space and number optional, but always needed together... It would match "Roller Coaster Tycoon" but not "Roller Coaster Tycoon "...