The following sort can be used to sort a Stem. In this algorithm, Stem_Variable is the stem.
I = COUNT
DO UNTIL I < 2
NEWI = 1
DO J = 1 UNTIL J >= I-1
K = J + 1
IF Stem_Variable.J > Stem_Variable.K THEN
DO
SWAP = Stem_Variable.K
Stem_Variable.K = Stem_Variable.J
Stem_Variable.J = SWAP
NEWI = J
END
END
I = NEWI
END
Subscribe to:
Post Comments (Atom)
Featured Post
REXX Skeleton: Submitting jobs through Rexx
Submitting jobs through REXX and reading the spool through REXX gives us immense potential to automate many manual activities in mainframes....
-
Abend S013 SYSTEM COMPLETION CODE=013 REASON CODE=00000018 AN OPEN WAS ISSUED FOR A PARTITIONED DATASET. THE SPECIFIED MEMBER NAME WAS N...
-
A word is defined as a blank delimited set of characters within a string in REXX. The characters in a word can be alpha, numeric, alphanume...
-
String functions interrogate, compare, and manipulate character strings of data. Some of the built-in function are listed below: COPIES...
No comments:
Post a Comment