#include <cstdio>
using namespace std;
int main(){
        long a,b,i;
        while(scanf("%ld %ld",&a,&b)!=EOF){
                i=1;a+=b;
                while(i>a) i*=10;
                printf("%ld",i-1);
        }
        return 0;
}