#include <iostream>
#include <cmath>
typedef long long ll;
using namespace std;

int main(){
    ll N, ans;
    cin >> N;
    for(ll i=1;i*i<=N;i++){
        if(N%i==0) ans = N/i;
    }
    ans = log10(ans)+1;
    cout << ans << endl;
    return 0;
}