YouTip LogoYouTip

Python Exercise Example56

# Python2.x Python Exercise Instance 56 [![Image 4: Python 100 Examples](#) Python 100 Examples](#) **Title:** Drawing, learn to draw circles using circle. **Program Analysis:** None. Program source code: ## Instance(Python 2.0+) ```python #!/usr/bin/python # -*- coding: UTF-8 -*- if __name__ == ' __main__ ': from Tkinter import * canvas = Canvas(width=800, height=600, bg='yellow') canvas.pack(expand=YES, fill=BOTH) k = 1 j = 1 for i in range(0,26): canvas.create_oval(310 - k,250 - k,310 + k,250 + k, width=1) k += j j += 0.3 mainloop() The output of the above instance is: ![Image
← Python Exercise Example57Python Exercise Example55 β†’