Question: 3 . Write a C program to determine the distance between two given points. According to the Pythagorean theorem, the distance between two points, denoted

3. Write a C program to determine the distance between two given points.
According to the Pythagorean theorem, the distance between two points, denoted as (x1,y1) and (x2,y2, can be calculated as the "square root of the sum of the squares of the differences in their respective x and y coordinates".
Theformula is :
d=(x2-x1)2+(y2-y1)22
Again, use the sqrt() function to calculate the square root of the number.
Submission: submit c file
4.The date June 10,1960, is special because when we write it in the following format, the month times the day equals the year.
610?60
Write a program that asks the user to enter a date in mm/dd/yy format. (two-digit year is required). The program should separate mm, dd, and yy into the variable month, date, and year. The program should then determine whether the month times the date is equal to the year. If so, it should display a message saying the date is magic. Otherwise, it should display a message saying the date is not magic.
Submission: submit c file
5. Scientists measure an object's mass in kilograms and its weight in newtons. If you know the amount of mass that an object has, you can calculate its weight in newtons with the following formula:
Weight = mass 9.8
Write a program that asks the user to enter an object's mass, then calculates anddisplays its weight. If the object weighs more than 1,000 newtons, display a message indicating it is too heavy. If the object weighs less than 10 newtons, display a message indicating that the object is too light.
 3. Write a C program to determine the distance between two

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!