Hi Monks, a small question have made me confuse.i want the result of dividing in the last part of script but i dont have it.please bring me out from this hell.thanks.

#!/usr/bin/perl -w use strict; use Bio::SeqIO; my $filename; print "enter file name="; $filename=<STDIN>; chomp $filename; open(RESULT,'>>result')or die "there isnt this file!"; #protein file bringing in. my $proteinio=Bio::SeqIO->new (-file=>"$filename",-format=>'fast +a'); while( my $seq=$proteinio ->next_seq() ){ foreach(my $protein=$seq->seq){ + my ($count_of_A,$count_of_C,$count_of_D,$count_of_E,$count_of_F,$count_of +_G,$count_of_H,$count_of_I,$count_of_K,$count_of_L,$co unt_of_M,$count_of_N,$count_of_P,$count_of_Q,$count_of_R,$count_of_S,$ +count_of_T,$count_of_V,$count_of_W,$count_of_Y)=0; my $id=$seq->id; # amino acid counting per sequence. my @prot=split("",$protein); my $tt=scalar (@prot); foreach my $aa(@prot){ if ( $aa=~ /A/ ){ $count_of_A++;} elsif ($aa=~/C/ig){ $count_of_C++;} elsif ($aa=~/D/ig){ $count_of_D++;} elsif ($aa=~/E/ig){ $count_of_E++;} elsif ($aa=~/F/ig){ $count_of_F++;} elsif ($aa=~/G/ig){ $count_of_G++;} elsif ($aa=~/H/ig){ $count_of_H++;} elsif ($aa=~/I/ig){ $count_of_I++;} elsif ($aa=~/K/ig){ $count_of_K++;} elsif ($aa=~/L/ig){ $count_of_L++;} elsif ($aa=~/M/ig){ $count_of_M++;} elsif ($aa=~/N/ig){ $count_of_N++;} elsif ($aa=~/P/ig){ $count_of_P++;} elsif ($aa=~/Q/ig){ $count_of_Q++;} elsif ($aa=~/R/ig){ $count_of_R++;} elsif ($aa=~/S/ig){ $count_of_S++;} elsif ($aa=~/T/ig){ $count_of_T++;} elsif ($aa=~/V/ig){ $count_of_V++;} elsif ($aa=~/W/ig){ $count_of_W++;} elsif ($aa=~/Y/ig){ $count_of_Y++;} } print RESULT "$id $count_of_A/$tt $count_of_C/$tt $count_of_D/$tt $co +unt_of_E/$tt $count_of_F/$tt $count_of_G/$tt $count_of_H/$tt $count_of_I/$tt $count_of_K/$tt $count_of_L/$tt $count +_of_M/$tt $count_of_N/$tt $count_of_P/$tt $count_of_Q/$tt $count_of_R/$tt $count_of_S/$tt $count_of_T/$tt $count +_of_V/$tt $count_of_W/$tt $count_of_Y/$tt \n"; } } close RESULT;

In reply to dividing numbers by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.