000100 IDENTIFICATION DIVISION.
000200 PROGRAM-ID. ZIPCODRB.
000300 AUTHOR.  Ryan Brooks.
000400 DATA DIVISION.
000500 WORKING-STORAGE SECTION.
000600 01  ZipCode PIC 99999 VALUE ZERO.
000700     88 STLArea              VALUE 63000 THRU 63999.
000800     88 KCArea               VALUE 64000 THRU 64999.
000900     88 OutStateMO           VALUE 65000 THRU 65999.
001000     88 EastSTL              VALUE 62000 THRU 62999.
001100     88 OutStateIL           VALUE 61000 THRU 61999.
001200     88 ChicagoArea          VALUE 60000 THRU 60999.
001300
001400 PROCEDURE DIVISION.
001500 Begin.
001600 MAIN-THREAD.
001700    DISPLAY "Enter a 5-digit zipcode - " WITH NO ADVANCING.
001800    ACCEPT ZipCode.
001900    PERFORM CHECK-CORRECT-INPUT.
002000    IF STLArea OR KCArea OR ChicagoArea OR EastSTL
002100           DISPLAY "Zipcode " ZipCode " is 2-day shipping"
002200    ELSE IF OutStateMO OR OutStateIL
002300           DISPLAY "Zipcode " ZipCode " is 3-day shipping"
002400    else
002500         DISPLAY "Zipcode " ZipCode " is 4-day shipping"
002600    END-IF
002700 GOBACK.
002800
002900 CHECK-CORRECT-INPUT.
003000    IF ZipCode IS NUMERIC
003100     IF ZipCode > 9999
003200         CONTINUE
003300     ELSE
003400         DISPLAY "You must enter 5 digits"
003500         CONTINUE
003600     END-IF
003700   ELSE
003800     DISPLAY "You must enter numerical values only"
003900     go to MAIN-THREAD.
004000*  END-IF
004100*  DISPLAY "----------"
004200   CONTINUE.
