if ($str =~ /^e\d+$/i) { # $str besteht nur aus E oder e, gefolgt von Ziffern    print "okay"; } else {    print "ungueltig!"; }