programming-examples/perl/Subroutine/Using my if statement.pl
2019-11-15 12:59:38 +01:00

16 lines
319 B
Perl

$testvalue = 10;
if ((my $variable1 = 10) > $testvalue ) {
print "Value, $variable1, is greater than the test value.\n";
} elsif ($variable1 < $testvalue) {
print "Value, $variable1, is less than the test value.\n";
} else {
print "Value, $variable1, is equal to the test value.\n";
}