int MatchTimes(String sub,String s){
int len=sub.length(),count=0,offset=0;
while(true)
{
int temp=s.indexOf(sub,offset);
if(temp!=-1)
{
offset=temp+len;
count++;
}
else break;
}
return count;
}
int len=sub.length(),count=0,offset=0;
while(true)
{
int temp=s.indexOf(sub,offset);
if(temp!=-1)
{
offset=temp+len;
count++;
}
else break;
}
return count;
}