cobol IF with shortform conditionals


IF A = 1 OR 2 THEN
    perform miracles

IF A = 1 OR 2 AND B = 1 THEN
    perform rites-of-passage
    perform song-and-dance

IF statements can be terminated with full stop or explicit scope terminator END-IF. Use of periods for scope termination is no longer recommended. Full stops mean just that in the case of nested IF, all nesting is terminated at the first full stop ., and any subsequent code will be outside the IF block.