Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- TString TString::operator%(TString &s2)//--------------------(!!!!!)
- {
- TString sop;
- int sz;
- sz=strlen(str)+strlen(s2.str)-2;
- sop.str=new char[sz+1];
- sop.str[0]=sz;
- strcpy(sop.str+1,this->str+1);
- bool flag;
- for(int i=1,k=strlen(sop.str)-1; i<strlen(sop.str); i++)
- {
- flag=true;
- for(int j=1;j<strlen(s2.str);j++)
- {
- if(sop.str[i]==s2.str[j])
- {
- flag=false;
- break;
- }
- }
- if(flag)
- {
- sop.str[k]=s2.str[i];
- sop.output();
- k++;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement