printing without spaces

Lee Harr missive at frontiernet.net
Wed Nov 21 00:24:48 CET 2001


>> >>> for i in range(3):
>>
>> 	for j in range(10):
>> 		print "%d%d" % (i,j),
>> 	print
>>
>>
>> 00 01 02 03 04 05 06 07 08 09
>> 10 11 12 13 14 15 16 17 18 19
>> 20 21 22 23 24 25 26 27 28 29
>>

o = ''
for i in range(3):
   for j in range(10):
      o += "%s%s" % (i,j)
   print o
   o = ''



More information about the Python-list mailing list