Hi, Your Mother. Can you please explain this snippet? It does print out the randomly assigned value of $success if I change it to:
exit ! main();
sub main { $success = [ undef, "true" ]->[rand 2]; print "$success\n"
+}
But it appears to produce the same output when I omit the
!:
exit main();
sub main { $success = [ undef, "true" ]->[rand 2]; print "$success\n"
+}
Which appears to be the same code as The Vague One posted ...
What is the function of the bang?
The way forward always starts with a minimal test.