#include <iostream>
#include <vector>
#include <cmath>

using namespace std;

int main(){
	long long n;
	cin >> n;
	int b;
	
	for(long long i=sqrt(n); i>=1; i--){
		if(n%i==0){
			b= n/i;
			break;
		}
	}
	
	cout << int(log10(b))+1 << endl;
	return 0;
}
