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
nikdorinn [45]
3 years ago
7

Enter the following code to calculate the distance between two points on the x, y plane. The program asks a user to enter 2 poin

ts, then calculates the distance between the 2 points and prints out the distance on the screen. You need to replace any "?" with the appropriate code. #include #include - Since you are using the math library, you'll need to include the -Im option when compiling, for example: gec extra4.c-Im-o extra4 struct point float x; float y: }; float distance (struct point, struct point); void enter_a_point ( struct point *); int main (void) struct point pti, pt2; enter_a_point(?); //get x 6 y values for pti enter_a_point(?): //get x & y values for pt2 printf( "Distance between the points=4.2f\n", distance(?, ?) ); return 0; Distance Formula float distance (struct point p1, struct point p2) 4 = (x - x) + (y - y) return sart pow( ?, 2) - powl ?, 2)); < void enter_a_point ( struct point p) printf("\nEnter an X coordinate: "); scanf("f", ?); printf("\nEnter a y coordinate: "); scanf("%f", ?);
Computers and Technology
1 answer:
nikklg [1K]3 years ago
5 0

Answer:

Explanation:

Ok, I don't understand anything at the end because it's utter gibberish.

What you can do, based on the question, is ask user input for the two x and two y coordinates, then use the distance formula. The distance is \sqrt{(x_1-x_2)^2+(y_1-y_2)^2} . Find a way to insert that using the math library.

Hope that helped,

-FruDe

You might be interested in
Different uses of quick access toolbar
zhannawk [14.2K]
“The Quick Access Toolbar provides access to frequently used commands, and the option to customize the toolbar with the commands that you use most often. By default, the New, Open, Save, Quick Print, Run, Cut, Copy, Paste, Undo, and Redo buttons appear on the Quick Access Toolbar” -Information Builders
5 0
3 years ago
Give me a code that draws a house with a roof in python. Please Answer!!!
Varvara68 [4.7K]

import turtle

window = turtle.Screen()

tr = turtle.Turtle()

tr.forward(100)

tr.left(90)

tr.forward(100)

tr.left(90)

tr.forward(100)

tr.left(90)

tr.forward(100)

tr.back(100)

tr.left(120)

tr.forward(75)

tr.right(78)

tr.forward(60)

window.mainloop()

In my code, we use the turtle module for the graphics to draw the house with a roof.

8 0
3 years ago
The Research and Development Process has five steps what are they ?
valentina_108 [34]

Answer:

The answer to this question is given below in the explanation section.

Explanation:

There are five steps used in any research and development project.

Step 1 – Locating and Defining Issues or Problems and get an idea about what is needed

Step 2 – Designing the Research Project, How you will solve the problem or get the solution of the problem

Step 3 – Collecting Data.

Step 4 – Interpreting Research Data.  

Step 5 – Report Research Findings.

3 0
3 years ago
Describe how an alpha channel and masking color control image transparency.
Stella [2.4K]
Answe:

Control image transparency
3 0
3 years ago
you type out a few sentences in an ms word file, and save it on your desktop. how is this data stored in the computer?
rosijanka [135]

When one is  typing on MS word and one save the file, this data would be stored as combination of 1s and 0s in the computer.

  • Computer data storage can be regarded complex system, immediately a data is saved then;

  • The first be converted to simple numbers of 1s and 0s , this number are very easy for a computer to store and these number are regarded as Binary Numbers and all letters as well as photographs are converted to numbers,

  • The hardware will record this saved numbers inside the computer.

  • These numbers are then  organized and transferred to temporary storage which be manipulated by programs, or software.

Therefore, data are been stored as 1s and 0s in the computer.

Learn more at:brainly.com/question/21571591?referrer=searchResults

8 0
3 years ago
Other questions:
  • (GAME DESIGN)
    15·1 answer
  • In the processes tab of task manager, the ____ tab displays the âworking setâ of a process, or the amount of memory it is active
    12·1 answer
  • What type of maintenance can prevent the computer from breaking?
    11·2 answers
  • Your program is going to compare the distinct salaries of two individuals for the last 5 years. If the salary for the two indivi
    15·1 answer
  • Whats the wire that connects to the wifi box
    15·2 answers
  • What is a computer?
    8·1 answer
  • Stacy plans to print her contacts and would like to choose an option that will print select information for each contact in a bu
    12·1 answer
  • First person to make me laugh will get brainliest.​
    10·2 answers
  • Gus has decided to organize his inbox on June 26 by using folders and deleting irrelevant messages. He creates a folder called "
    12·2 answers
  • Select the correct answer.
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!