Execute SNUSP/Perl: Difference between revisions
m
Fixed syntax highlighting.
m (Mwn3d moved page RCSNUSP/Perl to Execute SNUSP/Perl: Task changed names) |
m (Fixed syntax highlighting.) |
||
Line 19:
Here's the main program:
<
use strict;
use warnings;
Line 295:
EX
__END__</syntaxhighlight>
The following is the file which is included by each compiled perl program.
Line 303 ⟶ 302:
the main program.
<
use strict;
use warnings;
Line 359 ⟶ 358:
1;
__END__</syntaxhighlight>
Here's a basic Hello, World! program, which I found at:
http://www.quirkster.com/iano/snusp/snusp-js.html
<
+++ ++ ++ ++
+++ ++ /++++\ ++ ++ /++++\
Line 381 ⟶ 379:
. +> + + + + +- - +- -.
\.+/\++/ \++++/ + . +\ /-.+/- --
\ / \< / \ / \/</syntaxhighlight>
When compiled, the SNUSP code above produces the Perl code below:
<
use strict;
use warnings;
Line 419 ⟶ 415:
goto (pop @st);# U_40_9 '#'
STACK_UNDERFLOW: ;
EXIT: exit($data[$col] || 0);</syntaxhighlight>
This code produces:
|