Exercise 1:
import easygui
easygui.msgbox("I love Python")
Exercise 2:
import easygui as g
result = g.msgbox(msg = "I like Python so much.",title = "Show love",ok_button = "must")
print(result)
Exercise 3:
import easygui as g
flavor= g.buttonbox("Please choose your favorite flavor",title= "Icecream order system",choices= ("milk","vanilla","strawberry","Matcha"))
g.msgbox("What you choose is "+flavor+"\nplease confirm",title= "Icecream order system")
Homework:
import easygui as g
movie = g.buttonbox("Please pick a movie.",title = "Movie Order",
choices = ("Kubo and the Two Strings","Firefly","Car 3"))
number = g.buttonbox("How many tickets will you buy?",title = "Movie Order",
choices = ("1","2","3"))
g.msgbox("The movie you picked is :"+movie +", Tickets: "+number,title = "Movie Order")
[…] Magic Variable| |____Unit 4 Basic Operations| |____Unit 5 Data Types| |____Unit 6 Data Input| |____Unit 7 GUI design I| |____Unit 8 GUI design II|____Python Level 2| |____Unit 9 bool data type and relational operators| […]