cowboy007 has asked for the wisdom of the Perl Monks concerning the following question:
My code is doing like this:-Chr21 NT_113958 STS 76092 76265 Chr21 NT_113958 number=1
My output is coming like this:-while(<FH>) { chomp($_); $_ =~ s/^\s+//; $_ =~ s/\s+$//; if(($_ =~ /\A(\S+)\t(\S+)\t(\S+)\t(\S+)\t(\S+)/xmg) || ($_ =~ / +number\=(\S+)/xmg)) { print "$1\t$2\t$3\t$4\t$5\t$6\n"; } }
But I want it to be like this:-Chr21 NT_113958 STS 76092 76265 1
Can somebody give me clue what I should do ? ThanksChr21 NT_113958 STS 76092 76265 1
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Formatting clue
by toolic (Bishop) on Feb 18, 2009 at 03:02 UTC | |
by cowboy007 (Initiate) on Feb 18, 2009 at 03:16 UTC | |
|
Re: Formatting clue
by graff (Chancellor) on Feb 18, 2009 at 03:45 UTC | |
|
Re: Formatting clue
by scott\b (Novice) on Feb 18, 2009 at 14:51 UTC | |
|
Re: Formatting clue
by Anonymous Monk on Feb 18, 2009 at 06:54 UTC | |
by AnomalousMonk (Archbishop) on Feb 18, 2009 at 12:03 UTC |