from random import choice f = open('c:/documents and settings/viper/desktop/tables.html','w') hex = ['1','2','3','4','5','6','7','8','9','0','a','b','c','d','e','f'] f.write("
| \n" %('10%',choice(hex)+choice(hex)+choice(hex)+choice(hex)+choice(hex)+choice(hex))) f.write(" |