*23456789 *23456789 *23456789 *23456789 *23456789 *23456789 *23456789 *23456789 *23456789 *23456789 *23456789 *23456789 *23456789 
      PROGRAM HPC

      CHARACTER*132 CARD1,FIL1,FIL2
      CHARACTER*1 CHUC(26),CHLC(26)
      DATA CHUC/'A','B','C','D','E','F','G','H','I','L','M','N',
     &'O','P','Q','R','S','T','U','V','Z','W','Y','X','J','K'/
      DATA CHLC/'a','b','c','d','e','f','g','h','i','l','m','n',
     &'o','p','q','r','s','t','u','v','z','w','y','x','j','k'/
*
      FIL1=' '
      CALL GETARG(1,FIL1)
      LL=LSTNBL(FIL1)
      IF(LL.LE.0) THEN
         WRITE(*,'(''TYPE THE INPUT FILE:'',$)')
         READ(*,'(A)')FIL1
      ENDIF
      OPEN(UNIT=1,FILE=FIL1,STATUS='OLD')
      DO I=1,1000000000
         READ(1,'(A)',END=100)CARD1
         IF ( CARD1(1:10) .EQ. '/*$ CREATE') THEN
            I0=12
            DO J=1,100
               IF (CARD1(I0:I0).NE.' ') GO TO 200
               I0=I0+1
            END DO
            STOP '??????? All blanks!!!!'
  200       CONTINUE
            I1=INDEX(CARD1,'.C')-1
            FIL2=CARD1(I0:I1)//'.C'
            LEN=I1-I0+3
            CALL UCTOLC(FIL2,LEN)
            CLOSE (UNIT=2)
            WRITE(*,'('' Now opening '',A)') FIL2(1:LEN)
            OPEN (UNIT=2,FILE=FIL2,STATUS='UNKNOWN')
         END IF
         LQ=LSTNBL(CARD1)
         IF ( LQ .GT. 0 ) THEN
            WRITE(2,'(A)') CARD1(1:LQ)
         ELSE
            WRITE(2,*)
         END IF
      END DO
100   CONTINUE
      CLOSE (UNIT=1)
      CLOSE (UNIT=2)
      STOP
      END

      INTEGER FUNCTION LSTNBL (CARD)
      CHARACTER CARD*(*)
      LENG=LEN(CARD)
      DO INDX=LENG,1,-1
         IF ( CARD(INDX:INDX) .NE. ' ' ) GO TO 100
      END DO
  100 CONTINUE
      LSTNBL=INDX
      END

      SUBROUTINE UCTOLC (CARD,LEN)

      CHARACTER CARD*132
      CHARACTER*1 CHUC(26),CHLC(26)
      DATA CHUC/'A','B','C','D','E','F','G','H','I','L','M','N',
     &'O','P','Q','R','S','T','U','V','Z','W','Y','X','J','K'/
      DATA CHLC/'a','b','c','d','e','f','g','h','i','l','m','n',
     &'o','p','q','r','s','t','u','v','z','w','y','x','j','k'/
      SAVE CHUC, CHLC
*
      DO INDX=LEN,1,-1
         DO ICH=1,26
            IF ( CARD(INDX:INDX) .EQ. CHUC(ICH) )
     &         CARD(INDX:INDX)=CHLC(ICH)
         END DO
      END DO
      RETURN
      END

      SUBROUTINE LCTOUC (CARD,LEN)

      CHARACTER CARD*132
      CHARACTER*1 CHUC(26),CHLC(26)
      DATA CHUC/'A','B','C','D','E','F','G','H','I','L','M','N',
     &'O','P','Q','R','S','T','U','V','Z','W','Y','X','J','K'/
      DATA CHLC/'a','b','c','d','e','f','g','h','i','l','m','n',
     &'o','p','q','r','s','t','u','v','z','w','y','x','j','k'/
      SAVE CHUC, CHLC
*
      DO INDX=LEN,1,-1
         DO ICH=1,26
            IF ( CARD(INDX:INDX) .EQ. CHUC(ICH) )
     &         CARD(INDX:INDX)=CHLC(ICH)
         END DO
      END DO
      RETURN
      END
