#include <iostream>
using namespace std;
int main(void){
    // Here your code !
    int a,b;
    int num;
    cout<<"enter the first number:"<<endl;cin>>a;
    cout<<"enter the second number:"<<endl;cin>>b;
    scanf("%d %d", &a, &b);
    while(a!=0 && b!=0){
        num+= a%10;
        num = a/10;
        num+= b%10;
        num = b/10;
    }
     printf("\nSum of digits = %d", num);
    
}