import java.util.*;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int i = 0;
    
    while (i >= 0) {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    }
    
    System.out.println(i+1);
  }
} import java.util.*; util.* java public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int i = 0;
    
    while (i >= 0) {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    }
    
    System.out.println(i+1);
  }
} Main public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int i = 0;
    
    while (i >= 0) {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    }
    
    System.out.println(i+1);
  } main {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int i = 0;
    
    while (i >= 0) {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    }
    
    System.out.println(i+1);
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int K = sc.nextInt(); K sc.nextInt() sc.nextInt sc int i = 0; i 0 while (i >= 0) {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    } i >= 0 i 0 {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    } if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      } (int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N (int)Math.pow(K,i) <= N (int)Math.pow(K,i) Math.pow Math K i N (int)Math.pow(K,i+1) > N (int)Math.pow(K,i+1) Math.pow Math K i+1 i 1 N {
        break;
      } break; i++ i System.out.println(i+1) System.out.println System.out System System.out i+1 i 1 String[] args args public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int i = 0;
    
    while (i >= 0) {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    }
    
    System.out.println(i+1);
  }
} public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int i = 0;
    
    while (i >= 0) {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    }
    
    System.out.println(i+1);
  }
} Main
import java.util.*;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int K = sc.nextInt();
    int i = 0;
    
    while (i >= 0) {
      if ((int)Math.pow(K,i) <= N && (int)Math.pow(K,i+1) > N) {
        break;
      }
      i++;
    }
    
    System.out.println(i+1);
  }
}