Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
23
Task/String-append/COBOL/string-append.cobol
Normal file
23
Task/String-append/COBOL/string-append.cobol
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
identification division.
|
||||
program-id. string-append.
|
||||
|
||||
data division.
|
||||
working-storage section.
|
||||
01 some-string.
|
||||
05 elements pic x occurs 0 to 80 times depending on limiter.
|
||||
01 limiter usage index value 7.
|
||||
01 current usage index.
|
||||
|
||||
procedure division.
|
||||
append-main.
|
||||
|
||||
move "Hello, " to some-string
|
||||
|
||||
*> extend the limit and move using reference modification
|
||||
set current to length of some-string
|
||||
set limiter up by 5
|
||||
move "world" to some-string(current + 1:)
|
||||
display some-string
|
||||
|
||||
goback.
|
||||
end program string-append.
|
||||
Loading…
Add table
Add a link
Reference in a new issue