#include <bits/stdc++.h>
using namespace std;

const int INF = 1e9;

int main() {
  long n;
  cin>>n;
  long s = (long)sqrt(n);

  for (long i=s; i>0; i--) {
    if (n % i == 0) {
      int m = max(i, n / i);
      cout<<(int)(log10(m))+1<<endl;
      break;
    }
  }
}