I have a question on flip-flop operator. I have a script something like this
while (<>) { if(/START/.../END TIME (.+)/) { next if(/START/ | /^\s*$/); print; } }
The flop string 'END TIME (.+)' has a variable time at the end which I would like to extract and print. I see that the script match the 'END TIME (.+)', returns false and returns to the while loop beginning, but the matched sub-pattern (.+) is not stored anywhere ($1, $&, $+ etc). How do I extract this ?
Thanks in advance
-RajaIn reply to saving matching pattern with flip-flop operator by raja_infy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |