I have a text file and I want to display all words that contains both z and x characters.
How can I do that ?
>>> import re >>> print re.findall('(\w*x\w*z\w*|\w*z\w*x\w*)', 'axbzc azb axb abc axzb') ['axbzc', 'axzb']