Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I have problem to find the average; Declare two integer variables (int a=7, b=10;) and a float variable (float average;). Compute the average of a
I have problem to find the average;
Declare two integer variables (int a=7, b=10;) and a float variable (float average;). Compute the average of a and b and store the result in average. Do this in three ways: one way that results in an integer division and two other ways that result in a floating-point division. Produce an output like the one shown below. Integer division result: 8.000000 Floating-point division result #1: 8.500000 Floating-point division result #2: 8.500000Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started