      PROGRAM DIGITS

      INTEGER N,K
      READ(*,*) N,K

      DO 100 I=1,100

      N=N/K
!      WRITE(*,*) N
      if( N.LT.1 ) THEN
        GOTO 200
      ENDIF

  100 CONTINUE

  200 WRITE(*,*)I

      STOP
      END
