bembry.org
Home / Technology / Python / Exercises

Tkinter LEsson 6 Exercises: Bitmaps, Images, and Cursors

Each assignment should omit the root.mainloop() method call at the end of the code. Also, each program must include a title for the window. Save these programs as tk6-1.py, tk6-2.py, etc.

Exercise 1:
Create a GUI that has an image and a fancy cursor. Some feature on the GUI should also call a new window, which will include a bitmap along with some text. Have fun with this one.
Exercise 2:
Create a gif-viewer program. The application should create a list of all gif files in a directory and display each gif file when it is selected.
Exercise 3:
Create a "memory / matching" game. The game should have a series of buttons, which are randomly assigned "hidden" pictures. When each button is pressed, it displays the hidden picture. If two matching images are selected, both buttons should be disabled. When all buttons are disabled, a screen should pop up saying that the user has won.

Lesson Exercises Python Lessons Homepage

Restricted access