Guest User

Untitled

a guest
May 25th, 2018
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. void RastiZodi ( string eilute, string skyrikliai, string duotZod, int & pradzia )
  2. {
  3. int temp=0;
  4. pradzia=0;
  5. while (temp != -1) {
  6. temp = eilute.find(duotZod, pradzia);
  7. if (temp != -1) {
  8. int tmp = temp+duotZod.length() + 2;
  9. if((eilute.find_first_of(skyrikliai, temp-1) != -1) && (eilute.find_first_of(skyrikliai, temp+duotZod.length()) <= temp+duotZod.length()+2)) { pradzia = temp; temp=-1; }
  10. else { pradzia = temp+duotZod.length(); }
  11.  
  12. }
  13. }
  14. }
Add Comment
Please, Sign In to add comment