Anonymous user
Sort three variables: Difference between revisions
→{{header|Strings}}
Line 497:
\ non-destructive print 3 counted-strings from data stack
: .STRS ( caddr1 caddr2 caddr3 --
</LANG>
With these extensions we can do the same testing at the Forth console and
examine the string order with '.STRS'.
<PRE> ok
X Y Z ok
.S <3> 2142061672 2142061760 2142061848 ok
.STRS
lions, tigers, and▼
(from the "Wizard of OZ")
bears, oh my!
▲lions, tigers, and ok
SORT3STRINGS ok
.S <3> 2142061848 2142061760 2142061672 ok
.STRS
(from the "Wizard of OZ")▼
lions, tigers, and
bears, oh my!
▲(from the "Wizard of OZ") ok</PRE>
=={{header|Fortran}}==
|