in reply to Extraction of numbers in an string
I have the following string
A1=<m,n>:<p,q>:<s,t>...go on
I have to extract values m,n,p,q,s,t from the above string. How do i do it?.
You could use m// to match them:
#!/usr/bin/env perl use strictures; my @v = 'A1=<m,n>:<p,q>:<s,t>...go on' =~ /[mnpqst]/g;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Extraction of letters from a string
by t-rex (Scribe) on Nov 24, 2016 at 13:19 UTC | |
by hippo (Archbishop) on Nov 24, 2016 at 13:24 UTC | |
by t-rex (Scribe) on Nov 24, 2016 at 15:50 UTC | |
by AnomalousMonk (Archbishop) on Nov 24, 2016 at 15:57 UTC | |
by t-rex (Scribe) on Nov 24, 2016 at 13:30 UTC |