Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Loop through file to create interval tree

by Laurent_R (Abbot)
on May 23, 2014 at 18:07 UTC ( #1087249=note: print w/replies, xml ) Need Help??


in reply to Loop through file to create interval tree

Please fix your formatting to make your code readable. Put one opening <code> at the beginning of the code, one closing </code> tag at the end of your code, and no <code> tag in the middle of your comments.

Otherwise, your splitting is very inefficient. You could get your 3 variables in just one operation:

while (my $line=<$fh>){ chomp $line; my ($low, $high, $id) = split /\t/, $line; # ...

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1087249]
help
Chatterbox?
Discipulus manamanà
erix tu-tuu-tududu
Discipulus english has serious problems that reflect on programming terms..
[Discipulus]: ++erix
[Lady_Aleena]: Hello.
[Discipulus]: why github use 'pull request' instead of 'push request'? where is the subject?

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (7)
As of 2017-05-27 20:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?