33 |
34 | f.write('<table width=100%>\n')
35 | f2.write('<table width=100%>\n')
36 | tr = 0
37 | count = 1
38 | List = []
39 |
40 | for i in range(50000):
41 | . . x1 = gen_number(4) * gen_number(4)
42 | . . x2 = gen_number(7)
43 | . . b = x1 + x2
44 | . . c = x1 * x2
45 | . .
46 | . . m = str(b) + ' ' + str(c)
47 | . . . . . .
48 | . . if comp_List(List, m):
49 | . . . . List.append(m)
50 | . . . . if b != 0 and abs(c) < 126:
51 | . . . . . . if tr == 0:
52 | . . . . . . . . f.write('<tr>')
53 | . . . . . . . . f2.write('<tr>')
54 | . . . . . . f.write('<td><p>')
55 | . . . . . . f.write(str(count) + ') x<sup>2</sup> '+ show_numb(b*-1) + 'x ' +show_numb(c) + ' = 0' )
56 | . . . . . . f.write('</p></td>\n')
57 | . . . . . . f2.write('<td><p>')
58 | . . . . . . f2.write(str(count) + ') x<sub>1</sub> = '+ str(x1) + '; x<sub>2</sub> = ' + str(x2) )
59 | . . . . . . f2.write('</p></td>\n')
60 | . . . . . . count += 1
61 | . . . . . . tr += 1
62 | . . . . . . if tr == 3: