1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Marina CMI [18]
3 years ago
5

Implement a program that requests the user to enter the x and y coordinates (each between 10 and 10) of a dart and computes whet

her the dart has hit the dartboard, a circle with center (0,0) and radius 8. If so, string It is in! should be printed on the screen.
Computers and Technology
1 answer:
igomit [66]3 years ago
4 0

Answer:

Following are the program in the Python Programming Language.

#import math package

from math import sqrt

#define function

def circle(x,y):

 #return the square root

 return sqrt( (x)**2 + (y)**2 )

#get input from the user

x = float(input("Enter first number between -10 and 10: "))

#get input from the user

y = float(input("Enter first number between -10 and 10: "))

#check condition

if(circle(x,y)<8):

 #then, print message

 print("It is in!")

#otherwise

else:

 #print message

 print("It is not in!")

<u>Output:</u>

Enter first number between -10 and 10: 1.5

Enter first number between -10 and 10: 2.6

It is in!

Explanation:

Here, in the following program in the Python Programming Language.

  • Define the function "circle" and pass the argument "x" and "y" then, return square root of x and y.
  • Set a variable "x" which get float type input from the user.
  • Set a variable "y" which get float type input from the user.
  • Set the if conditional statement to check that the function return the value less than 8 then, print the message.
  • Otherwise, it print the following message.
You might be interested in
In symmetric key cryptosystem, assume that Alice and Bob have set up a common key Kab. This key is only known to Alice and Bob.
azamat

Answer:

yes

Explanation:

If it is guranteed the key is only known to Alice and Bob and there is no risk of man in the middle attack or channel spoofing so we can achieve data origin authentication

4 0
2 years ago
A school principal trying to find out if parents will help buy new playground equipment shows digital leadership by.
ELEN [110]

Answer:

D. is the correct answer!

8 0
3 years ago
Read 2 more answers
Identify the parts used in an electric circuit- Tiles
Svetlanka [38]
<span>
battery = </span>a source of energy<span>
buzzer = </span>electric energy into sound energy<span>
motor = </span>a device used to transfer electric energy into motion<span>
off switch = </span><span>a device used to break the flow of current</span><span>
</span>
3 0
2 years ago
Read 2 more answers
Which course must first-time drivers in Florida take to be eligible for their Learner License?
Travka [436]
The Traffic Law and Substance Abuse Course (TLSAE), which is also known as the drug and alcohol course.
7 0
3 years ago
Which attributes are indicators that a website is reliable? Check all that apply is up to date explains sources of data is an ed
Ahat [919]

Answer:

1 - Is up to date

2 - explains sources of data

3 - is an educational website

6 - will not share personal information

7 - has articles written by experts

7 0
2 years ago
Other questions:
  • Mike is reading about machine-dependent programming languages. Which languages are machine-dependent programming languages?
    11·1 answer
  • When did the silver market drop sharply, hurting Bolivia's income?
    7·2 answers
  • Write a program that uses these bounds and bisection search (for more info check out the Wikipedia page on bisection search) to
    8·1 answer
  • What is a row of data in a database called?<br> Field<br> File<br> Record<br> Title
    10·1 answer
  • Please help if you answer correcly i will give you brainelst!!!!!!!!!!!!!!!!!!
    6·2 answers
  • Which of the following statements is FALSE?
    5·1 answer
  • What is the best food to eat before workout? why?​
    10·2 answers
  • Which is the fastest memory in computer​
    9·2 answers
  • Impromptu speaking ability is very important in the workplace to clearly and effectively communicate ideas. An effective impromp
    8·2 answers
  • Please help me.
    8·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!