int numJewelsInStones(char * jewels, char * stones){
int len1=strlen(jewels);
int len2=strlen(stones);
int count=0;
for(int a=0;a<len1;a++){
for(int b=0;b<len2;b++){
if(jewels[a]==stones[b]){
count++;
}
}
}
return count;
}
09-14
221
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
12-30
668
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)