from Tkinter import *
from random import *
import time
tk = Tk()
w = Canvas(tk, width=200, height=200)
def line(event):
x1=0
x2=0
x3 = randint(0,200)
x4 = randint(0,200)
w.create_line(x1, x2, x3, x4)
w.bind("<Button-1>",line)
w.pack()
mainloop()
from Tkinter import *
from random import *
import time
tk = Tk()
w = Canvas(tk, width=200, height=200)
def line(event):
x1=0
x2=0
x3 = randint(0,200)
x4 = randint(0,200)
w.create_line(x1, x2, x3, x4)
w.bind("<Button-1>",line)
w.pack()
mainloop()