#include<stdio.h>
#include<string.h>
int main()
{int i,j,len,count=0;
char a[100];
int c[100];
gets(a);
len=strlen(a);
for(i=len-1,j=0;i>=0;i-=2,j++)
{if(i-1<0){c[j]=a[i]-'0';count++;
}c[j]=(a[i-1]-'0')*10+(a[i]-'0');
count++;
}
int sum=0;
for(i=0;i<count;i++)
{sum+=c[i];
}
if(sum%11==0)printf("Yes");
else printf("No");
return 0;
}
标签:count,11.16,sum,++,len,int,printf From: https://blog.51cto.com/u_15758636/5856015