#include <stdio.h> int main() { long long a,b,i,j,i1,j1; scanf("%lld%lld%lld%lld",&a,&i,&b,&j); i1=0,j1=0; while (a){ if(a%10==i){ i1=i1*10+i; } a/=10; } while (b){ if(b%10==j){ j1=j1*10+j; } b/=10; } printf("%lld",i1+j1); return 0; }
// 部分A+B
标签:10,i1,j1,long,while,第二天,lld% From: https://www.cnblogs.com/vat---/p/17504269.html