
while( $seq = <STDIN> )
{
    chomp( $seq );
    print "Sequence : $seq\n";
    if ( $seq =~ /GATATC/ )
        { 
            print "Fragment : ", length( $` ) + 3, "\n";
            $seq = $';
            while( $seq =~ /GATATC/ )
                {
                    print "Fragment : ", length( $` ) + 6, "\n";
                    $seq = $';
                }
            print "Fragment : ", length( $seq ) + 3, "\n\n";
        }
    else
        {
            print "No cutting sites. One fragment of length ", length( $seq), "\n\n";
        }
}
