S = 'xxxxSPAMxxxxSPAMxxxx' where = S.find('SPAM') # search for position print where # occurs at offset 4