Hi, i'm looking for a way to use eval expression in perl regexp. for example. if i want to match the following pattern X_(X+1)_(X+2) using a single code line, where X represent a numeric value. i.e. 1_2_3 but not 1_2_2
i'd like to know if the following pseudo code can be written in perl:
so far what i do is grouping the first numeral, and use it to create the consecutive numerals, and add them all to my regexp
thanks alot
i'd like to know if the following pseudo code can be written in perl:
Code:
([0-9]+)_eval(\1+1)_eval(\1+2)
thanks alot
Comment