Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Bracketing Substring(s) in the String

by sapnac (Beadle)
on Aug 25, 2005 at 17:36 UTC ( #486657=note: print w/replies, xml ) Need Help??


in reply to Bracketing Substring(s) in the String

map{$s1 =~ s/$_/[$_]/g} @a1; map{$s2 =~ s/$_/[$_]/g} @a2; map{$s3 =~ s/$_/[$_]/g} @a3; map{$s4 =~ s/$_/[$_]/g} @a4; print join("\n",$s1,$s2,$s3,$s4)."\n"; gives; CCC[ATCTG]TCCTT[ATTTG]CTG AC[CCATC]TGTCCTTGGCCAT [CCACC]A[GCACC]TGTC C[CCAAC]ACCTGCTGCCT Is this what you want? If not, Please give what is expected to happen +for the last 2 strings. Hope this helps!

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://486657]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (7)
As of 2020-11-27 15:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?