      SUBROUTINE INSERTFOR2000(nn,c,file,maxchar)

c     INSERTFOR2000 INSERTS A LETTER IN PLACE OF
C     THE FIRST DIGIT FOR YEARS GREATER THAN 1999.
C     IN A DESIGNATED SPOT IN A FILE NAME.

C     nn - input full year/output one digit representing
c          second digit of year
c     character to replace
c     file - full file name

C     EXAMPLES:  FOR FILE OF FORM YEARNN.DATA, WHERE
C      NN=LAST TWO DIGITS OF YEAR
C       input nn=1999, c=N, file=YEARNN.DATA
C       output nn=1999, c=N, file=YEARNN.DATA
C 
C       input nn=2002, c=N, file=YEARNN.DATA
C       output nn=2, c=N, file=YEARAN.DATA
C      
C       input nn=2011, c=N, file=YEARNN.DATA
C       output nn=1, c=N, file=YEARBN.DATA 

      character*(*) file
      character*1 c
      character*1 cadd(0:9)

      data cadd/'A','B','C','D','E','F','G','H','I','J'/

      if ( nn .le. 1999 ) then
       nn=nn-1900
      else
       n2=nn-2000
       nx=n2/10
       call findchar(nadd,file,maxchar,c)
       if ( nadd .le. maxchar) file(nadd:nadd)=cadd(nx)
       nn=n2-(nx*10)
      endif

      return
      end

