String repetition
Naked if statement
if statement - comparing valuesYou can compare two values or scalar variables using the if statement and one of the comparison operators.examples/scalars/if.p6 #!/usr/bin/perl6
use v6;
my $age = 23;
if ($age > 18) {
say "You can vote in most countries.";
}
Copyright 2006, 2007, 2008, 2009, 2010 Gabor Szabo http://szabgab.com/ Index | TOC |