Fix rank computation.
This commit is contained in:
parent
ba919f8e0a
commit
c8eea4e215
10
words.py
10
words.py
|
@ -68,15 +68,15 @@ while Q:
|
|||
db.commit()
|
||||
|
||||
r = db.execute('''
|
||||
select q.word, q.rank
|
||||
from words q
|
||||
select q.word, q.rank, z.rank
|
||||
from words q, words z
|
||||
where not exists (
|
||||
select *
|
||||
from combos c
|
||||
where c.x = q.word and c.y = ?
|
||||
)
|
||||
''', (z,))
|
||||
for q, q_rank in r.fetchall():
|
||||
) and z.word = ?
|
||||
''', (z, z))
|
||||
for q, q_rank, z_rank in r.fetchall():
|
||||
Q.add(((z, z_rank), (q, q_rank)))
|
||||
|
||||
time.sleep(5)
|
||||
|
|
Loading…
Reference in New Issue