pre_match and post_match for subexpressions

Discussion in 'Ruby' started by trans. (T. Onoma), Oct 24, 2004.

  1. md = /(X)(Y)(Z)/.match "<<<XYZ>>>"

    md.pre_match(2) #=> "<<<X"
    md.post_match(2) #=> "Z>>>"



    T.
    trans. (T. Onoma), Oct 24, 2004
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    4
    Views:
    554
  2. Sergey Dorofeev

    subexpressions

    Sergey Dorofeev, Jun 1, 2007, in forum: Python
    Replies:
    20
    Views:
    648
    Alex Martelli
    Jun 4, 2007
  3. Steve Howell

    Re: subexpressions

    Steve Howell, Jun 2, 2007, in forum: Python
    Replies:
    2
    Views:
    257
    Stef Mientki
    Jun 2, 2007
  4. Steve Howell

    Re: subexpressions (OT: math)

    Steve Howell, Jun 2, 2007, in forum: Python
    Replies:
    23
    Views:
    609
    Wildemar Wildenburger
    Jun 4, 2007
  5. Paolo Bonzini
    Replies:
    0
    Views:
    82
    Paolo Bonzini
    Feb 6, 2008
Loading...

Share This Page