HDU 2017

 1 #include<stdio.h>
 2 
 3 int main()
 4 {
 5         int T;
 6         char st[10000];
 7         scanf("%d",&T);
 8         while(T--)
 9         {
10         int x=0;
11         int i;
12         scanf("%s",st );
13         for(i=0;st[i];++i )
14         {
15             if( st[i]<=57&&st[i]>=48 )
16             x++;
17         }
18         printf("%d\n",x);
19     }
20 }
posted on 2012-10-21 23:48  McDong  阅读(146)  评论(0)    收藏  举报