Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Python (.py file) You have recently been hired by Nintendo to write a program that calculates the distance between two pokemon in Nintendo's latest iPhone/Android
Python (.py file)
You have recently been hired by Nintendo to write a program that calculates the distance between two pokemon in Nintendo's latest iPhone/Android App, Pokemon Go. Your program should work as follows: 1. Ask the user for the name of the first pokemon 2. Ask the user for the first pokemon's X coordinate 3. Ask the user for the first pokemon's Y coordinate 4. Ask the user for the name of the second pokemon 5. Ask the user for the second pokemon's X coordinate 6. Ask the user for the second pokemon's Y coordinate 7. Print out the distance between the two pokemon Here is a copy of the distance formula in case you haven't taken geometry in a while: / (x2-x1 )2 + (y2- y1 )2 Below is a sample running of your program: RESTART : Pokemon Distance Calculator 1. Enter name of first pokemon: Charmander 2. Enter name of second pokemon: Blastoise 3. Enter x coordinate of first pokemon: 3.28 4. Enter y coordinate of first pokemon: 2.258882 5. Enter x coordinate of second pokemon: 3.923995 6. Enter y coordinate of second pokemon: 3 The distance between Charmander and Blastoiseis 0.98 inches RESTART Pokemon Distance Calculator 1. Enter name of first pokemon: Pikachu 2. Enter name of second pokemon: Onix 3. Enter x coordinate of first pokemon: 5 4. Enter y coordinate of first pokemon: 5 5. Enter x coordinate of second pokemon: 5 6. Enter y coordinate of second pokemon: 5 The distance between Pikachu and Onix 0.00 inches
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started