Question Details
Description
Answer Download
The Question
My code isn't working, please help. Here is the problem:
Create your own function in C that accepts one input parameter and returns a float number. Youdecide the theme.You should provide both your C code and an example call to the C code function. Be sure toprovide an overview of what your function is doing.Provide a screen capture showing the results of testing your code in an online compiler.Be sure to test your code with several test cases and show your test case table.Submit your word or PDF file to your assignments folder no later than the due date.
Here is my code, which isn't working. Please tell me what is wrong
// C code
// This program will calculate the average of 3
// Developer: Walee Khan
// Date: March 6, 2016
#include
float Average(int);
int main ()
{
int value, sum, count, intsum;
float avg;
count = 3;
sum = 0;
while (count
printf("Enter number of heat races runn");
scanf("%d", &value);
if (value >= 0)
{
sum = sum + value;
count = count - 1;
}
else {
printf("Only enter positive integersn");
}
}
avg = Average(intsum);
printf("Average of heat race times is %fn", avg);
return 0;
}
float Average(int sum)
{
return sum/3.0;
}
Solution details
Solution #000121860
Pay using PayPal (No PayPal account Required) or your credit card . All your purchases are securely protected by .
About this Question
STATUSAnswered
QUALITYApproved
DATE ANSWEREDOct 14, 2020
EXPERTTutor
ANSWER RATING
BEST TUTORS
We have top-notch tutors who can do your essay/homework for you at a reasonable cost and then you can simply use that essay as a template to build your own arguments.
You can also use these solutions:
- As a reference for in-depth understanding of the subject.
- As a source of ideas / reasoning for your own research (if properly referenced)
- For editing and paraphrasing (check your institution's definition of plagiarism and recommended paraphrase).
STUCK WITH YOUR PAPER?
Order New Solution. Quick Turnaround
Click on the button below in order to Order for a New, Original and High-Quality Essay Solutions. New orders are original solutions and precise to your writing instruction requirements. Place a New Order using the button below.
WE GUARANTEE, THAT YOUR PAPER WILL BE WRITTEN FROM SCRATCH AND WITHIN A DEADLINE.
