1.Python Tkinter
Libraries used
tkinter- TKINTER is the standard GUI library used to provide fast and easy way to create GUI applications.<br>
random- RANDOM Module is a built-in module which is used to give random numbers or choices by providing a set of methods.<br>
It's aim is to assign a house name to the user when he/she clicks the button.
Step 1: Import all the packages listed above.
Step 2: Then a list consisting of house names is created.
Step 3: Function "pickHouse" is defined to randomly select a house for the user.
Step 4: Then main window is created with a title and size. Label and button is added to the window.
Step 5: When we run the program, tkinter window appears with a label and a button "Choose your house".When the button is clicked , the house name which is assigned to you is displayed.
Output Screenshots
PyGamesScripts\sorting hat game\Images\initial_img.png
PyGamesScripts\sorting hat game\Images\first_output.png
PyGamesScripts\sorting hat game\Images\second_output.png
Kamakshi Singh