Jump to content

Munching squares: Difference between revisions

m
→‎{{header|Perl 6}}: fix file open error handling
m (→‎{{header|Perl 6}}: fix file open error handling)
Line 902:
Here's one simple way:
 
<lang perl6>my $ppm = open("munching0.ppm", :w) ororelse .die;
die "Can't create munching.ppm: $!";
 
$ppm.print(q :to 'EOT');
Line 931 ⟶ 930:
 
 
my $PPM = open "munching1.ppm", :w ororelse .die "Can't create munching.ppm: $!";
 
$PPM.print: qq:to/EOH/;
2,392

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.