#include using namespace std; int main(){ cin.tie(0),ios::sync_with_stdio(false); string s,t; cin>>s>>t; int ans=0; auto pos=s.find(t,0); while(pos!=string::npos){ s.at(pos)='.'; pos=s.find(t,pos+1); ++ans; } if(ans&&t.size()==1)ans=-1; cout<