Turecko-americká vycházející matematická hvězda Levent Alpöge ze společnosti Anthropic vyvolal pozdvižení oznámením (PDF), že s pomocí superinteligence Claude od Antropicu dokázal vyřešit jeden ze sedmi největších matematických problémů tisíciletí, slavnou Riemannovu hypotézu (prvočísla se mezi čísly objevují zdánlivě nepravidelně, hypotéza tvrdí, že za jejich rozmístěním je určitý řád). Svůj důkaz uvolnil jako open-source
… více »
#============================================================================
# Test-Function
#----------------------------------------------------------------------------
if __name__ == '__main__':
from Tkinter import Tk, Label, Button
import pprint
prn = pprint.PrettyPrinter(indent = 6).pprint
def test_cmd(event=None):
if event.i == 0:
return '%i, %i' % (event.r, event.c)
else:
return 'set'
def browsecmd(event):
print "event:", event.__dict__
print "curselection:", test.curselection()
print "active:", test.index('active', 'row')
print "anchor:", test.index('anchor', 'row')
root = Tk()
#root.tk.call('load', '', 'Tktable')
var = ArrayVar(root)
for y in range(-1, 4):
for x in range(-1, 5):
index = "%i,%i" % (y, x)
var.set(index, index)
label = Label(root, text="Proof-of-existence test for Tktable")
label.pack(side = 'top', fill = 'x')
quit = Button(root, text="QUIT", command=root.destroy)
quit.pack(side = 'bottom', fill = 'x')
test = Table(root,
rows=10,
cols=5,
state='disabled',
width=6,
height=6,
titlerows=1,
titlecols=1,
roworigin=-1,
colorigin=-1,
selectmode='browse',
selecttype='row',
rowstretch='unset',
colstretch='last',
browsecmd=browsecmd,
flashmode='on',
variable=var,
usecommand=0,
command=test_cmd)
test.pack(expand=1, fill='both')
test.tag_configure('sel', background = 'yellow')
test.tag_configure('active', background = 'blue')
test.tag_configure('title', anchor='w', bg='red', relief='sunken')
root.mainloop()
#----------------------------------------------------------------------------
Jinak našel jsem to na CVS tady.
Tiskni
Sdílej: