Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: substrings that consist of repeating characters

by GrandFather (Saint)
on Sep 27, 2020 at 22:26 UTC ( [id://11122273]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use strict;
    use warnings;
    ...
    length $1 >= $threshold && (push @runs, $1) while $string =~ /(A+|C+|G
    ++|T+)/g;
    @runs = sort {length($b) <=> length($a)} @runs;
    printf "@runs\n";
    
  2. or download this
    CCCCCC GGGG AAA TTT TTT TTT
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others exploiting the Monastery: (2)
As of 2024-04-26 05:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found