def occurrences(text1, text2):
    """Return the number of times characters from text1 occur in text2
    occurrences(string, string) -> int
    """
for c in text1:
    print(c)
if c in text2:
    pass
print(occurrences('fooled', 'hello world'))
Processing strings in a loop