Advertisement
Guest User

Untitled

a guest
Jan 21st, 2017
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.57 KB | None | 0 0
  1. if( Check(len1, len2, str1, str2) )
  2. {
  3. for(int i = 0; i < len2; i++)
  4. {
  5. for(int j = 0; j < len1; j++)
  6. {
  7.  
  8. // Check to see if str2 at position i is equal
  9. // to the character at str1 position j
  10.  
  11. if str2[i] == str1[j]:
  12. // It is! Now check to see if it's been found already
  13. if hasBeenFound(found_letters, str1[j])
  14. // Apparently it hasn't! hasBeenFound returned a 1
  15. // So now str1 at position j will be added to our found letters
  16. found_letters.add(str1[j])
  17.  
  18. }
  19.  
  20. }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement