programming-examples/perl/Statement/unless statement with else.pl

7 lines
123 B
Perl
Raw Normal View History

2019-11-15 12:59:38 +01:00
$variable = 6;
unless ($variable == 5) {
print "No, it's not five.\n";
} else {
print "Yes, it's five.\n";
}