#!/usr/bin/perl -w
# Show how to use opertor chaining in flow control 

# Read the protein sequence data from the file one line at a time and print it
while ($protein = <STDIN>) {
	chomp($protein);
	if (!$protein) {
		die "Done.\n";
	} elsif ($protein =~ /^[ACGTacgt]*$/) {
		$protein = uc $protein;
		print "Sequence entered: $protein\n";
	} else {
		print "Invalid sequence!\n";
	}
}