标签:a10 amp int abs class long ret sum lib
#include<cstdio>
#include<cstdlib>
int main(){
long A, B, C, SUM;
scanf("%ld%ld", &A, &B);
SUM = A + B;
C = abs(SUM);
if(C < 1000)
printf("%ld", SUM);
if(C >= 1000 && C < 1000000)
printf("%ld,%03ld", SUM/1000, C%1000);
if(C >= 1000000)
printf("%ld,%03ld,%03ld", SUM/1000000, (C/1000)%1000, C%1000);
return 0;
}
标签:a10 amp int abs class long ret sum lib
原文地址:https://www.cnblogs.com/zjsaipplp/p/10425265.html