i am trying to calculate hours it takes to complete each week depending on if user asks for total or average, this is not the full code but the part shown is one that should do the calculation. I am trying to first calculate for total.
float calc_hours(int hours[], int weeks, char output)
{
int total = 0;
{
for (i = 0 ; i < weeks ; i++)
{
total += hours;
}
}
}