Error returned at line 27 (line beginning with "charges") stating "undeclared reference (for the calculateCharge, to my best guess) and compiler notes says "ld returned 1 exit status" I can't for the life of me get what need to change.
float calculateCharge(float);
int main()
{
  printf("Hello world!\n");
  int car;
  int num_cars;
  float total_charges = 0;
  float total_hours = 0;
  printf("How many cars?\n\n");      //prompt
  scanf("%d", &num_cars);            //prompt
  float hours [num_cars + 1];        //declaring parallel arrays
  float charges [num_cars + 1];
  for (car=1; car<=num_cars; car++)
  {
      printf("How many hours for car #%d?", car);     //prompt
      scanf("%f", &hours[car]);                       //input hours
      charges [car] = calculateCharge(hours [car]);
      total_charges = total_charges + charges [car];
      total_hours = total_hours + hours [car];
  }
  printf("%s\t%s\t%s\t", "Car", "Hours", "Charge");
  for (car = 1; car <=num_cars; car++)
  {
       printf("\n%d\t%.2f\t%.2f\n", car, hours[car], charges[car]);
  }
printf("\n%s\t%.2f\t%.2f\n", "Total", total_hours, total_charges);
return 0;
}
 
     
    