Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Include Write three C statements that declare the following integer variables and initialize each to zero: num1 num2 num3 Write one C statement that declares

Include

  • Write three C statements that declare the following integer variables and initialize each to zero: num1 num2 num3
  • Write one C statement that declares the following floating point variable: myAverage
  • Write C statements that store: 125 into num1 28 into num2 -25 into num3
  • Write a C statement that stores the average of num1, num2, and num3 into the variable myAverage
  • Write C statements that output the values of num1, num2, num3, and myAverage;
    • with labels like "num1 = ..."
    • each on their own lines
  • Write a C statement to return a 0 at the completion of the program

Output should look like.

num1 = 125

num2 = 28

num3 = -25

average = 42.66667

 

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

Students also viewed these Databases questions