I want to write a program that would take a string, let\'s say \"Fox\", then it would display:
\"Fox\"
fox, F
>>> import itertools >>> map(''.join, itertools.product(*((c.upper(), c.lower()) for c in 'Fox'))) ['FOX', 'FOx', 'FoX', 'Fox', 'fOX', 'fOx', 'foX', 'fox']
Or
>>> s = 'Fox' >>> map(''.join, itertools.product(*zip(s.upper(), s.lower())))