Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a program to perform the following: Write a C program to read inputs for m1, m2, G and r. Find value of F based

image text in transcribed
image text in transcribed
Write a program to perform the following: Write a C program to read inputs for m1, m2, G and r. Find value of F based on following condition: r value must be more than zero mm2 F=G p2 Note: Write your ID and name as comment Sample Output Sample Output Enter ml value 3 Enter m2 value 5 Enter G value 4 Enter r value -5 r value must be more than zero Enter ml value 4 Enter m2 value 5 Enter G value 3 Enter r value 4.3 Result is 13.953487 1 A 22 . Copy the below code, correct any eight errors and paste corrected progra #include stdio.h> int main() { float a, B.c, Avg Int total; printf("Enter three integer values "); scanf("%d %d %d", &a, &b, &c) total a+b+c avg = a+b+c/3 print("Average is %f" Avg); return 0; }

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Practical Database Programming With Visual Basic.NET

Authors: Ying Bai

1st Edition

0521712351, 978-0521712354

More Books

Students also viewed these Databases questions

Question

=+How might you explain this phenomenon?

Answered: 1 week ago