So, i have this problem. I got tuple (1,2,3) which i should print with string formatting. eg.
tup = (1,2,3)
print \"this is a tuple %something\" % (tup)
This doesn't use string formatting, but you should be able to do:
print 'this is a tuple ', (1, 2, 3)
If you really want to use string formatting:
print 'this is a tuple %s' % str((1, 2, 3))
# or
print 'this is a tuple %s' % ((1, 2, 3),)
Note, this assumes you are using a Python version earlier than 3.0.