The choice() function from random module is helpful for this purpose. It returns one item (a character in case of a string) randomly from string (any sequence object for that matter)
>>> import random >>> string='TutorialsPoint' >>> ch=random.choice(string) >>> ch 'n' >>> ch=random.choice(string) >>> ch 'u'