      SUBROUTINE MAIN
      LOGICAL*1 C, ARGBUF(128)
      LOGICAL*1 CLOWER
      INTEGER FD
      INTEGER OPEN
      INTEGER ARGNO, I
      INTEGER CTOI, GETARG, GETLIN
      INTEGER INCREM
      INTEGER PREPND
      INTEGER LINNUM
      INTEGER NUMDIG
      INTEGER ZFILL
      LOGICAL*1 LIN
      INTEGER NUMCOL
      INTEGER TABSPC
      LOGICAL*1 ST001Z(62)
      COMMON /CNUM/ LINNUM, NUMDIG, ZFILL, LIN(402)
      COMMON /CPOST/ NUMCOL, TABSPC
      DATA ST001Z(1)/117/,ST001Z(2)/115/,ST001Z(3)/97/,ST001Z(4)/103/,ST
     *001Z(5)/101/,ST001Z(6)/58/,ST001Z(7)/32/,ST001Z(8)/32/,ST001Z(9)/1
     *10/,ST001Z(10)/117/,ST001Z(11)/109/,ST001Z(12)/98/,ST001Z(13)/101/
     *,ST001Z(14)/114/,ST001Z(15)/32/,ST001Z(16)/91/,ST001Z(17)/45/,ST00
     *1Z(18)/102/,ST001Z(19)/93/,ST001Z(20)/32/,ST001Z(21)/91/,ST001Z(22
     *)/45/,ST001Z(23)/122/,ST001Z(24)/93/,ST001Z(25)/32/,ST001Z(26)/91/
     *,ST001Z(27)/45/,ST001Z(28)/105/,ST001Z(29)/60/,ST001Z(30)/110/,ST0
     *01Z(31)/62/,ST001Z(32)/93/,ST001Z(33)/32/,ST001Z(34)/91/,ST001Z(35
     *)/45/,ST001Z(36)/115/,ST001Z(37)/60/,ST001Z(38)/110/,ST001Z(39)/62
     */,ST001Z(40)/93/,ST001Z(41)/32/,ST001Z(42)/91/,ST001Z(43)/45/,ST00
     *1Z(44)/100/,ST001Z(45)/60/,ST001Z(46)/110/,ST001Z(47)/62/,ST001Z(4
     *8)/93/,ST001Z(49)/32/,ST001Z(50)/91/,ST001Z(51)/45/,ST001Z(52)/93/
     *,ST001Z(53)/32/,ST001Z(54)/102/,ST001Z(55)/105/,ST001Z(56)/108/,ST
     *001Z(57)/101/,ST001Z(58)/32/,ST001Z(59)/46/,ST001Z(60)/46/,ST001Z(
     *61)/46/,ST001Z(62)/0/
      LINNUM = 1
      INCREM = 1
      NUMDIG = 7
      PREPND = 1
      ZFILL = 0
      NUMCOL = 73
      TABSPC = 8
      CALL QUERY( ST001Z)
      ARGNO = 1 
23000 IF (.NOT.(GETARG( ARGNO, ARGBUF, 128) .NE. -1 ))GOTO 23002
      IF (.NOT.( ARGBUF(1) .EQ. 45 ))GOTO 23003
      IF (.NOT.( ARGBUF(2) .EQ. 0 ))GOTO 23005
      FD = 1
      GOTO 23006
23005 CONTINUE
      C = CLOWER(ARGBUF(2))
      I = 3
      IF (.NOT.( C .EQ. 102 ))GOTO 23007
      PREPND = 0
      NUMDIG = 8
23007 CONTINUE
      IF (.NOT.( C .EQ. 122 ))GOTO 23009
      ZFILL = 1
23009 CONTINUE
      IF (.NOT.( C .EQ. 105 ))GOTO 23011
      INCREM = CTOI( ARGBUF, I)
23011 CONTINUE
      IF (.NOT.( C .EQ. 115 ))GOTO 23013
      LINNUM = CTOI( ARGBUF, I)
23013 CONTINUE
      IF (.NOT.( C .EQ. 100 ))GOTO 23015
      NUMDIG = CTOI( ARGBUF, I)
23015 CONTINUE
      CALL DELARG(ARGNO)
      ARGNO = ARGNO - 1
      GOTO 23001
23006 CONTINUE
      GOTO 23004
23003 CONTINUE
      FD = OPEN( ARGBUF, 1)
      IF (.NOT.( FD .EQ. -3 ))GOTO 23017
      CALL CANT(ARGBUF)
23017 CONTINUE
23004 CONTINUE
23019 IF (.NOT.(GETLIN(LIN, FD) .NE. -1 ))GOTO 23021
      IF (.NOT.( PREPND .EQ. 1 ))GOTO 23022
      CALL PRE
      GOTO 23023
23022 CONTINUE
      CALL POST
23023 CONTINUE
23020 LINNUM = LINNUM + INCREM 
      GOTO 23019
23021 CONTINUE
      CALL CLOSE(FD)
23001 ARGNO = ARGNO + 1 
      GOTO 23000
23002 CONTINUE
      RETURN
      END
      SUBROUTINE PRE
      INTEGER LINNUM
      INTEGER NUMDIG
      INTEGER ZFILL
      LOGICAL*1 LIN
      LOGICAL*1 NUM(20)
      INTEGER JUNK
      INTEGER GITOCF
      COMMON /CNUM/ LINNUM, NUMDIG, ZFILL, LIN(402)
      IF (.NOT.( ZFILL .EQ. 1 ))GOTO 23024
      JUNK = GITOCF( LINNUM, NUM, 20, 10, NUMDIG, 48)
      CALL PUTLIN( NUM, 2)
      GOTO 23025
23024 CONTINUE
      CALL PUTINT( LINNUM, NUMDIG,2)
23025 CONTINUE
      CALL PUTCH(32,2)
      CALL PUTLIN( LIN, 2)
      RETURN
      END
      SUBROUTINE POST
      INTEGER LINNUM
      INTEGER NUMDIG
      INTEGER ZFILL
      LOGICAL*1 LIN
      INTEGER NUMCOL
      INTEGER TABSPC
      LOGICAL*1 NUM(20)
      INTEGER LENGTH, MOD, GITOCF
      INTEGER JUNK
      LOGICAL*1 C
      INTEGER IINDEX
      INTEGER LINLEN
      INTEGER OINDEX
      COMMON /CNUM/ LINNUM, NUMDIG, ZFILL, LIN(402)
      COMMON /CPOST/ NUMCOL, TABSPC
      LINLEN = LENGTH(LIN)
      IF (.NOT.( LIN(LINLEN) .EQ. 10 ))GOTO 23026
      LIN(LINLEN) = 0
23026 CONTINUE
      OINDEX = 1
      IINDEX = 1 
23028 IF (.NOT.(LIN(IINDEX) .NE. 0 ))GOTO 23030
      C = LIN(IINDEX)
      OINDEX = OINDEX + 1
      IF (.NOT.( C .NE. 9 ))GOTO 23031
      CALL PUTCH(C,2)
      GOTO 23032
23031 CONTINUE
      CALL PUTCH(32,2)
23033 IF (.NOT.(MOD(OINDEX, TABSPC) .NE. 1 ))GOTO 23035
      CALL PUTCH(32,2)
23034 OINDEX = OINDEX + 1 
      GOTO 23033
23035 CONTINUE
23032 CONTINUE
23029 IINDEX = IINDEX + 1 
      GOTO 23028
23030 CONTINUE
23036 IF (.NOT.(OINDEX .LT. NUMCOL ))GOTO 23038
      CALL PUTCH(32,2)
23037 OINDEX = OINDEX + 1 
      GOTO 23036
23038 CONTINUE
      IF (.NOT.( ZFILL .EQ. 1 ))GOTO 23039
      JUNK = GITOCF( LINNUM, NUM, 20, 10, NUMDIG, 48)
      CALL PUTLIN( NUM, 2)
      GOTO 23040
23039 CONTINUE
      CALL PUTINT( LINNUM, NUMDIG,2)
23040 CONTINUE
      CALL PUTCH(10,2)
      RETURN
      END
