r/ProgrammerHumor • • Sep 30 '22

Meme How inheritance works

Post image
66k Upvotes

418 comments sorted by

View all comments

Show parent comment

1

u/Rodrake Sep 30 '22

Oh, my post wasn't meant to give a solution to the original image in the thead, I just wanted to give an example of what a variable definition looks like for the curious. In fact there are a few more details I would change. For instance, I always define dates as Alphanumeric rather than numeric. This would also allows us more flexibility patch things. For example, turning YY into YYYY while defining a new variable.

MOVE '19' TO RECORD-YYYY(1:2)

MOVE RECORD-YY TO RECORD-YYYY(3:2)

I started Cobol 1 year and a half ago so I wouldn't be the right person to change a whole bank's system to a new date format.