' ){ # if we're on a comment line, print the previous seq and move on print_seq(); echo $str, "\n"; }else{ # otherwise, just append to the sequence $seq .= $str; } } print_seq(); exit; # print the sequence out, if it exists function print_seq(){ global $seq; # no time-consuming argument passing for us! :) if($seq != ''){ echo wordwrap( strrev( strtr(strtoupper($seq), SRC, DST) ), LINE_LENGTH, "\n", true ), "\n"; } $seq = ''; } ?>