ength    PIC 99 VALUE ZEROS.



PROCEDURE DIVISION.
Begin.
*   Task1 substring(xStr, StartPos, Length)
*   Extract a substring from a string given the StartPos and Length.
*   Solution - use reference modification to get the substring.
*   In this example we get 3 characters starting at position 9
    DISPLAY "Task1 = " xStr(9:3)

*   Task2 prefix(xStr,Length)
*   Extract the first Length number of chars from a string
*   Solution - use reference modification starting at position 1.
*   In th