SlideShare a Scribd company logo
1 of 1
Python question.
9.16 Implement a GUI application that allows users to compute their body mass index (BMI),
which we defined in Practice Problem 5.1. Your GUI should look as shown below. Enter your
height: Enter your weight: Compute BMI After entering the weight and height and then clicking
the button, a new window should pop up with the computed BMI.Make sure your GUI is user
friendly by deleting the entered weight and height so that the user can enter new inputs without
having to erase the old ones.
Solution
BMI Calculator 1. Obtain weight in pounds and height in inches 2. Convert weight to kilograms
and height to meters 3. Calculate BMI with the formula weight/height^2 """ #prompt user for
input from keyboard weight= input ("How much do you weigh (in pounds)?") #this get's the
person's weight in pounds weight_in_kg= weight/2.2 #this converts weight to kilograms height=
input ("What is your height (in inches)?") #this gets the person's height in inches
height_in_meter=height*2.54/100 #this converts height to centimeters
bmi=weight_in_kg/(height_in_meter**2) #this calculates BMI print (bmi)

More Related Content

Similar to Python question- 9-16 Implement a GUI application that allows users to.docx

DOC333-2023-Sep-pythonprogramming-Lec04.pdf
DOC333-2023-Sep-pythonprogramming-Lec04.pdfDOC333-2023-Sep-pythonprogramming-Lec04.pdf
DOC333-2023-Sep-pythonprogramming-Lec04.pdfahamedmusharaf15
 
PYTHONNANGCAO_1.GUI.Creating the GUI Form and Adding Widgets.pptx
PYTHONNANGCAO_1.GUI.Creating the GUI Form and Adding Widgets.pptxPYTHONNANGCAO_1.GUI.Creating the GUI Form and Adding Widgets.pptx
PYTHONNANGCAO_1.GUI.Creating the GUI Form and Adding Widgets.pptxTrangNguyenThiHuyen6
 
P1.javaimport java.util.Scanner;keyboard inputting package pub.pdf
P1.javaimport java.util.Scanner;keyboard inputting package pub.pdfP1.javaimport java.util.Scanner;keyboard inputting package pub.pdf
P1.javaimport java.util.Scanner;keyboard inputting package pub.pdfaquacareser
 
Google calendar integration in iOS app
Google calendar integration in iOS appGoogle calendar integration in iOS app
Google calendar integration in iOS appKetan Raval
 
COMPUTER SCIENCE INVESTIGATORY PROJECT 2017-18
COMPUTER SCIENCE INVESTIGATORY PROJECT 2017-18COMPUTER SCIENCE INVESTIGATORY PROJECT 2017-18
COMPUTER SCIENCE INVESTIGATORY PROJECT 2017-18HIMANSHU .
 

Similar to Python question- 9-16 Implement a GUI application that allows users to.docx (6)

DOC333-2023-Sep-pythonprogramming-Lec04.pdf
DOC333-2023-Sep-pythonprogramming-Lec04.pdfDOC333-2023-Sep-pythonprogramming-Lec04.pdf
DOC333-2023-Sep-pythonprogramming-Lec04.pdf
 
PYTHONNANGCAO_1.GUI.Creating the GUI Form and Adding Widgets.pptx
PYTHONNANGCAO_1.GUI.Creating the GUI Form and Adding Widgets.pptxPYTHONNANGCAO_1.GUI.Creating the GUI Form and Adding Widgets.pptx
PYTHONNANGCAO_1.GUI.Creating the GUI Form and Adding Widgets.pptx
 
P1.javaimport java.util.Scanner;keyboard inputting package pub.pdf
P1.javaimport java.util.Scanner;keyboard inputting package pub.pdfP1.javaimport java.util.Scanner;keyboard inputting package pub.pdf
P1.javaimport java.util.Scanner;keyboard inputting package pub.pdf
 
Google calendar integration in iOS app
Google calendar integration in iOS appGoogle calendar integration in iOS app
Google calendar integration in iOS app
 
COMPUTER SCIENCE INVESTIGATORY PROJECT 2017-18
COMPUTER SCIENCE INVESTIGATORY PROJECT 2017-18COMPUTER SCIENCE INVESTIGATORY PROJECT 2017-18
COMPUTER SCIENCE INVESTIGATORY PROJECT 2017-18
 
Notification android
Notification androidNotification android
Notification android
 

More from gtameka

TOPIC- Landslide early warning in Costa Rica- Students are required to (1).docx
TOPIC- Landslide early warning in Costa Rica- Students are required to (1).docxTOPIC- Landslide early warning in Costa Rica- Students are required to (1).docx
TOPIC- Landslide early warning in Costa Rica- Students are required to (1).docxgtameka
 
Topic option 2- What should the rules be for computer crime- Your pape.docx
Topic option 2- What should the rules be for computer crime- Your pape.docxTopic option 2- What should the rules be for computer crime- Your pape.docx
Topic option 2- What should the rules be for computer crime- Your pape.docxgtameka
 
Tones Company purchased a warehouse in a downtown district where land.docx
Tones Company purchased a warehouse in a downtown district where land.docxTones Company purchased a warehouse in a downtown district where land.docx
Tones Company purchased a warehouse in a downtown district where land.docxgtameka
 
Tones Industries has the following patents on its December 31- 2013- b.docx
Tones Industries has the following patents on its December 31- 2013- b.docxTones Industries has the following patents on its December 31- 2013- b.docx
Tones Industries has the following patents on its December 31- 2013- b.docxgtameka
 
Toni Tornan is a single parent- During 2014 she earned wages $26-550-.docx
Toni Tornan is a single parent- During 2014 she earned wages $26-550-.docxToni Tornan is a single parent- During 2014 she earned wages $26-550-.docx
Toni Tornan is a single parent- During 2014 she earned wages $26-550-.docxgtameka
 
Toms construction site has a pipe that discharges run off from the sit.docx
Toms construction site has a pipe that discharges run off from the sit.docxToms construction site has a pipe that discharges run off from the sit.docx
Toms construction site has a pipe that discharges run off from the sit.docxgtameka
 
To achieve long-term prosperity- strategic planners commonly establish.docx
To achieve long-term prosperity- strategic planners commonly establish.docxTo achieve long-term prosperity- strategic planners commonly establish.docx
To achieve long-term prosperity- strategic planners commonly establish.docxgtameka
 
Tiffany MacGraw- a Canadian citizen- left Canada in 2005 to settle in.docx
Tiffany MacGraw- a Canadian citizen- left Canada in 2005 to settle in.docxTiffany MacGraw- a Canadian citizen- left Canada in 2005 to settle in.docx
Tiffany MacGraw- a Canadian citizen- left Canada in 2005 to settle in.docxgtameka
 
True or false- Social networking through such services as Facebook- Tw.docx
True or false- Social networking through such services as Facebook- Tw.docxTrue or false- Social networking through such services as Facebook- Tw.docx
True or false- Social networking through such services as Facebook- Tw.docxgtameka
 
True or False- In a proprietary system- a commercial vendor opens thei.docx
True or False- In a proprietary system- a commercial vendor opens thei.docxTrue or False- In a proprietary system- a commercial vendor opens thei.docx
True or False- In a proprietary system- a commercial vendor opens thei.docxgtameka
 
TRUE OR FALSE- 1- N- a nonresident alien individual- was born in Count.docx
TRUE OR FALSE- 1- N- a nonresident alien individual- was born in Count.docxTRUE OR FALSE- 1- N- a nonresident alien individual- was born in Count.docx
TRUE OR FALSE- 1- N- a nonresident alien individual- was born in Count.docxgtameka
 
True or False Explain Why- 1- SIP and RTP are protocols used to allow.docx
True or False Explain Why- 1- SIP and RTP are protocols used to allow.docxTrue or False Explain Why- 1- SIP and RTP are protocols used to allow.docx
True or False Explain Why- 1- SIP and RTP are protocols used to allow.docxgtameka
 
True or False 1- The interstellar medium is composed mostly of gaseous.docx
True or False 1- The interstellar medium is composed mostly of gaseous.docxTrue or False 1- The interstellar medium is composed mostly of gaseous.docx
True or False 1- The interstellar medium is composed mostly of gaseous.docxgtameka
 
True or False (1 point each) 1- TorF NOs is the only form of nitrogen.docx
True or False (1 point each) 1- TorF NOs is the only form of nitrogen.docxTrue or False (1 point each) 1- TorF NOs is the only form of nitrogen.docx
True or False (1 point each) 1- TorF NOs is the only form of nitrogen.docxgtameka
 
Transform the E-R diagram into a set of relations- Parking Tickets Ta.docx
Transform the E-R diagram into a set of relations-  Parking Tickets Ta.docxTransform the E-R diagram into a set of relations-  Parking Tickets Ta.docx
Transform the E-R diagram into a set of relations- Parking Tickets Ta.docxgtameka
 
Trace the evolution of the US police system from the --political-- era.docx
Trace the evolution of the US police system from the --political-- era.docxTrace the evolution of the US police system from the --political-- era.docx
Trace the evolution of the US police system from the --political-- era.docxgtameka
 
Trace the following part of codes step by step- Show exactly what it w.docx
Trace the following part of codes step by step- Show exactly what it w.docxTrace the following part of codes step by step- Show exactly what it w.docx
Trace the following part of codes step by step- Show exactly what it w.docxgtameka
 
Training and DevelopmentSolutionThe various skills that are necessary.docx
Training and DevelopmentSolutionThe various skills that are necessary.docxTraining and DevelopmentSolutionThe various skills that are necessary.docx
Training and DevelopmentSolutionThe various skills that are necessary.docxgtameka
 
Question 1 This layer of the OSI model is responsible for dialog contr.docx
Question 1 This layer of the OSI model is responsible for dialog contr.docxQuestion 1 This layer of the OSI model is responsible for dialog contr.docx
Question 1 This layer of the OSI model is responsible for dialog contr.docxgtameka
 
QUESTION 1 The purpose of an audit is to express an opinion on whether.docx
QUESTION 1 The purpose of an audit is to express an opinion on whether.docxQUESTION 1 The purpose of an audit is to express an opinion on whether.docx
QUESTION 1 The purpose of an audit is to express an opinion on whether.docxgtameka
 

More from gtameka (20)

TOPIC- Landslide early warning in Costa Rica- Students are required to (1).docx
TOPIC- Landslide early warning in Costa Rica- Students are required to (1).docxTOPIC- Landslide early warning in Costa Rica- Students are required to (1).docx
TOPIC- Landslide early warning in Costa Rica- Students are required to (1).docx
 
Topic option 2- What should the rules be for computer crime- Your pape.docx
Topic option 2- What should the rules be for computer crime- Your pape.docxTopic option 2- What should the rules be for computer crime- Your pape.docx
Topic option 2- What should the rules be for computer crime- Your pape.docx
 
Tones Company purchased a warehouse in a downtown district where land.docx
Tones Company purchased a warehouse in a downtown district where land.docxTones Company purchased a warehouse in a downtown district where land.docx
Tones Company purchased a warehouse in a downtown district where land.docx
 
Tones Industries has the following patents on its December 31- 2013- b.docx
Tones Industries has the following patents on its December 31- 2013- b.docxTones Industries has the following patents on its December 31- 2013- b.docx
Tones Industries has the following patents on its December 31- 2013- b.docx
 
Toni Tornan is a single parent- During 2014 she earned wages $26-550-.docx
Toni Tornan is a single parent- During 2014 she earned wages $26-550-.docxToni Tornan is a single parent- During 2014 she earned wages $26-550-.docx
Toni Tornan is a single parent- During 2014 she earned wages $26-550-.docx
 
Toms construction site has a pipe that discharges run off from the sit.docx
Toms construction site has a pipe that discharges run off from the sit.docxToms construction site has a pipe that discharges run off from the sit.docx
Toms construction site has a pipe that discharges run off from the sit.docx
 
To achieve long-term prosperity- strategic planners commonly establish.docx
To achieve long-term prosperity- strategic planners commonly establish.docxTo achieve long-term prosperity- strategic planners commonly establish.docx
To achieve long-term prosperity- strategic planners commonly establish.docx
 
Tiffany MacGraw- a Canadian citizen- left Canada in 2005 to settle in.docx
Tiffany MacGraw- a Canadian citizen- left Canada in 2005 to settle in.docxTiffany MacGraw- a Canadian citizen- left Canada in 2005 to settle in.docx
Tiffany MacGraw- a Canadian citizen- left Canada in 2005 to settle in.docx
 
True or false- Social networking through such services as Facebook- Tw.docx
True or false- Social networking through such services as Facebook- Tw.docxTrue or false- Social networking through such services as Facebook- Tw.docx
True or false- Social networking through such services as Facebook- Tw.docx
 
True or False- In a proprietary system- a commercial vendor opens thei.docx
True or False- In a proprietary system- a commercial vendor opens thei.docxTrue or False- In a proprietary system- a commercial vendor opens thei.docx
True or False- In a proprietary system- a commercial vendor opens thei.docx
 
TRUE OR FALSE- 1- N- a nonresident alien individual- was born in Count.docx
TRUE OR FALSE- 1- N- a nonresident alien individual- was born in Count.docxTRUE OR FALSE- 1- N- a nonresident alien individual- was born in Count.docx
TRUE OR FALSE- 1- N- a nonresident alien individual- was born in Count.docx
 
True or False Explain Why- 1- SIP and RTP are protocols used to allow.docx
True or False Explain Why- 1- SIP and RTP are protocols used to allow.docxTrue or False Explain Why- 1- SIP and RTP are protocols used to allow.docx
True or False Explain Why- 1- SIP and RTP are protocols used to allow.docx
 
True or False 1- The interstellar medium is composed mostly of gaseous.docx
True or False 1- The interstellar medium is composed mostly of gaseous.docxTrue or False 1- The interstellar medium is composed mostly of gaseous.docx
True or False 1- The interstellar medium is composed mostly of gaseous.docx
 
True or False (1 point each) 1- TorF NOs is the only form of nitrogen.docx
True or False (1 point each) 1- TorF NOs is the only form of nitrogen.docxTrue or False (1 point each) 1- TorF NOs is the only form of nitrogen.docx
True or False (1 point each) 1- TorF NOs is the only form of nitrogen.docx
 
Transform the E-R diagram into a set of relations- Parking Tickets Ta.docx
Transform the E-R diagram into a set of relations-  Parking Tickets Ta.docxTransform the E-R diagram into a set of relations-  Parking Tickets Ta.docx
Transform the E-R diagram into a set of relations- Parking Tickets Ta.docx
 
Trace the evolution of the US police system from the --political-- era.docx
Trace the evolution of the US police system from the --political-- era.docxTrace the evolution of the US police system from the --political-- era.docx
Trace the evolution of the US police system from the --political-- era.docx
 
Trace the following part of codes step by step- Show exactly what it w.docx
Trace the following part of codes step by step- Show exactly what it w.docxTrace the following part of codes step by step- Show exactly what it w.docx
Trace the following part of codes step by step- Show exactly what it w.docx
 
Training and DevelopmentSolutionThe various skills that are necessary.docx
Training and DevelopmentSolutionThe various skills that are necessary.docxTraining and DevelopmentSolutionThe various skills that are necessary.docx
Training and DevelopmentSolutionThe various skills that are necessary.docx
 
Question 1 This layer of the OSI model is responsible for dialog contr.docx
Question 1 This layer of the OSI model is responsible for dialog contr.docxQuestion 1 This layer of the OSI model is responsible for dialog contr.docx
Question 1 This layer of the OSI model is responsible for dialog contr.docx
 
QUESTION 1 The purpose of an audit is to express an opinion on whether.docx
QUESTION 1 The purpose of an audit is to express an opinion on whether.docxQUESTION 1 The purpose of an audit is to express an opinion on whether.docx
QUESTION 1 The purpose of an audit is to express an opinion on whether.docx
 

Recently uploaded

An Overview of the Odoo 17 Discuss App.pptx
An Overview of the Odoo 17 Discuss App.pptxAn Overview of the Odoo 17 Discuss App.pptx
An Overview of the Odoo 17 Discuss App.pptxCeline George
 
The impact of social media on mental health and well-being has been a topic o...
The impact of social media on mental health and well-being has been a topic o...The impact of social media on mental health and well-being has been a topic o...
The impact of social media on mental health and well-being has been a topic o...sanghavirahi2
 
Open Educational Resources Primer PowerPoint
Open Educational Resources Primer PowerPointOpen Educational Resources Primer PowerPoint
Open Educational Resources Primer PowerPointELaRue0
 
Basic phrases for greeting and assisting costumers
Basic phrases for greeting and assisting costumersBasic phrases for greeting and assisting costumers
Basic phrases for greeting and assisting costumersPedroFerreira53928
 
[GDSC YCCE] Build with AI Online Presentation
[GDSC YCCE] Build with AI Online Presentation[GDSC YCCE] Build with AI Online Presentation
[GDSC YCCE] Build with AI Online PresentationGDSCYCCE
 
The basics of sentences session 4pptx.pptx
The basics of sentences session 4pptx.pptxThe basics of sentences session 4pptx.pptx
The basics of sentences session 4pptx.pptxheathfieldcps1
 
Basic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
Basic Civil Engg Notes_Chapter-6_Environment Pollution & EngineeringBasic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
Basic Civil Engg Notes_Chapter-6_Environment Pollution & EngineeringDenish Jangid
 
50 ĐỀ LUYỆN THI IOE LỚP 9 - NĂM HỌC 2022-2023 (CÓ LINK HÌNH, FILE AUDIO VÀ ĐÁ...
50 ĐỀ LUYỆN THI IOE LỚP 9 - NĂM HỌC 2022-2023 (CÓ LINK HÌNH, FILE AUDIO VÀ ĐÁ...50 ĐỀ LUYỆN THI IOE LỚP 9 - NĂM HỌC 2022-2023 (CÓ LINK HÌNH, FILE AUDIO VÀ ĐÁ...
50 ĐỀ LUYỆN THI IOE LỚP 9 - NĂM HỌC 2022-2023 (CÓ LINK HÌNH, FILE AUDIO VÀ ĐÁ...Nguyen Thanh Tu Collection
 
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdf
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdfINU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdf
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdfbu07226
 
PART A. Introduction to Costumer Service
PART A. Introduction to Costumer ServicePART A. Introduction to Costumer Service
PART A. Introduction to Costumer ServicePedroFerreira53928
 
The Benefits and Challenges of Open Educational Resources
The Benefits and Challenges of Open Educational ResourcesThe Benefits and Challenges of Open Educational Resources
The Benefits and Challenges of Open Educational Resourcesaileywriter
 
The Art Pastor's Guide to Sabbath | Steve Thomason
The Art Pastor's Guide to Sabbath | Steve ThomasonThe Art Pastor's Guide to Sabbath | Steve Thomason
The Art Pastor's Guide to Sabbath | Steve ThomasonSteve Thomason
 
How to the fix Attribute Error in odoo 17
How to the fix Attribute Error in odoo 17How to the fix Attribute Error in odoo 17
How to the fix Attribute Error in odoo 17Celine George
 
The Last Leaf, a short story by O. Henry
The Last Leaf, a short story by O. HenryThe Last Leaf, a short story by O. Henry
The Last Leaf, a short story by O. HenryEugene Lysak
 
Basic_QTL_Marker-assisted_Selection_Sourabh.ppt
Basic_QTL_Marker-assisted_Selection_Sourabh.pptBasic_QTL_Marker-assisted_Selection_Sourabh.ppt
Basic_QTL_Marker-assisted_Selection_Sourabh.pptSourabh Kumar
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaasiemaillard
 

Recently uploaded (20)

An Overview of the Odoo 17 Discuss App.pptx
An Overview of the Odoo 17 Discuss App.pptxAn Overview of the Odoo 17 Discuss App.pptx
An Overview of the Odoo 17 Discuss App.pptx
 
The impact of social media on mental health and well-being has been a topic o...
The impact of social media on mental health and well-being has been a topic o...The impact of social media on mental health and well-being has been a topic o...
The impact of social media on mental health and well-being has been a topic o...
 
Open Educational Resources Primer PowerPoint
Open Educational Resources Primer PowerPointOpen Educational Resources Primer PowerPoint
Open Educational Resources Primer PowerPoint
 
Basic phrases for greeting and assisting costumers
Basic phrases for greeting and assisting costumersBasic phrases for greeting and assisting costumers
Basic phrases for greeting and assisting costumers
 
[GDSC YCCE] Build with AI Online Presentation
[GDSC YCCE] Build with AI Online Presentation[GDSC YCCE] Build with AI Online Presentation
[GDSC YCCE] Build with AI Online Presentation
 
The basics of sentences session 4pptx.pptx
The basics of sentences session 4pptx.pptxThe basics of sentences session 4pptx.pptx
The basics of sentences session 4pptx.pptx
 
Basic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
Basic Civil Engg Notes_Chapter-6_Environment Pollution & EngineeringBasic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
Basic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
 
NCERT Solutions Power Sharing Class 10 Notes pdf
NCERT Solutions Power Sharing Class 10 Notes pdfNCERT Solutions Power Sharing Class 10 Notes pdf
NCERT Solutions Power Sharing Class 10 Notes pdf
 
Word Stress rules esl .pptx
Word Stress rules esl               .pptxWord Stress rules esl               .pptx
Word Stress rules esl .pptx
 
50 ĐỀ LUYỆN THI IOE LỚP 9 - NĂM HỌC 2022-2023 (CÓ LINK HÌNH, FILE AUDIO VÀ ĐÁ...
50 ĐỀ LUYỆN THI IOE LỚP 9 - NĂM HỌC 2022-2023 (CÓ LINK HÌNH, FILE AUDIO VÀ ĐÁ...50 ĐỀ LUYỆN THI IOE LỚP 9 - NĂM HỌC 2022-2023 (CÓ LINK HÌNH, FILE AUDIO VÀ ĐÁ...
50 ĐỀ LUYỆN THI IOE LỚP 9 - NĂM HỌC 2022-2023 (CÓ LINK HÌNH, FILE AUDIO VÀ ĐÁ...
 
Operations Management - Book1.p - Dr. Abdulfatah A. Salem
Operations Management - Book1.p  - Dr. Abdulfatah A. SalemOperations Management - Book1.p  - Dr. Abdulfatah A. Salem
Operations Management - Book1.p - Dr. Abdulfatah A. Salem
 
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdf
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdfINU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdf
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdf
 
PART A. Introduction to Costumer Service
PART A. Introduction to Costumer ServicePART A. Introduction to Costumer Service
PART A. Introduction to Costumer Service
 
The Benefits and Challenges of Open Educational Resources
The Benefits and Challenges of Open Educational ResourcesThe Benefits and Challenges of Open Educational Resources
The Benefits and Challenges of Open Educational Resources
 
The Art Pastor's Guide to Sabbath | Steve Thomason
The Art Pastor's Guide to Sabbath | Steve ThomasonThe Art Pastor's Guide to Sabbath | Steve Thomason
The Art Pastor's Guide to Sabbath | Steve Thomason
 
How to the fix Attribute Error in odoo 17
How to the fix Attribute Error in odoo 17How to the fix Attribute Error in odoo 17
How to the fix Attribute Error in odoo 17
 
The Last Leaf, a short story by O. Henry
The Last Leaf, a short story by O. HenryThe Last Leaf, a short story by O. Henry
The Last Leaf, a short story by O. Henry
 
Post Exam Fun(da) Intra UEM General Quiz - Finals.pdf
Post Exam Fun(da) Intra UEM General Quiz - Finals.pdfPost Exam Fun(da) Intra UEM General Quiz - Finals.pdf
Post Exam Fun(da) Intra UEM General Quiz - Finals.pdf
 
Basic_QTL_Marker-assisted_Selection_Sourabh.ppt
Basic_QTL_Marker-assisted_Selection_Sourabh.pptBasic_QTL_Marker-assisted_Selection_Sourabh.ppt
Basic_QTL_Marker-assisted_Selection_Sourabh.ppt
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 

Python question- 9-16 Implement a GUI application that allows users to.docx

  • 1. Python question. 9.16 Implement a GUI application that allows users to compute their body mass index (BMI), which we defined in Practice Problem 5.1. Your GUI should look as shown below. Enter your height: Enter your weight: Compute BMI After entering the weight and height and then clicking the button, a new window should pop up with the computed BMI.Make sure your GUI is user friendly by deleting the entered weight and height so that the user can enter new inputs without having to erase the old ones. Solution BMI Calculator 1. Obtain weight in pounds and height in inches 2. Convert weight to kilograms and height to meters 3. Calculate BMI with the formula weight/height^2 """ #prompt user for input from keyboard weight= input ("How much do you weigh (in pounds)?") #this get's the person's weight in pounds weight_in_kg= weight/2.2 #this converts weight to kilograms height= input ("What is your height (in inches)?") #this gets the person's height in inches height_in_meter=height*2.54/100 #this converts height to centimeters bmi=weight_in_kg/(height_in_meter**2) #this calculates BMI print (bmi)