Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: Hexamer combination from 3mers.

by 2teez (Vicar)
on Oct 10, 2012 at 16:34 UTC ( #998255=note: print w/replies, xml ) Need Help??


in reply to Hexamer combination from 3mers.

Or you could simply use a foreach loop like so:

use warnings; use strict; my @three_mers = qw( ABC EFG KLM XYZ); foreach my $mers_first (@three_mers) { foreach my $mers_sec (@three_mers) { print $mers_first, $mers_sec, $/; } }
OUTPUT
ABCABC ABCEFG ABCKLM ABCXYZ EFGABC EFGEFG EFGKLM EFGXYZ KLMABC KLMEFG KLMKLM KLMXYZ XYZABC XYZEFG XYZKLM XYZXYZ

If you tell me, I'll forget.
If you show me, I'll remember.
if you involve me, I'll understand.
--- Author unknown to me

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://998255]
help
Chatterbox?
[erix]: if you're interested in tsv file reading in pg, look at file_fdw
[erix]: aka: create extension if not exists file_fdw;

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (5)
As of 2018-02-23 15:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    When it is dark outside I am happiest to see ...














    Results (302 votes). Check out past polls.

    Notices?