Question #279734

Write a c program that reads a number representing the amount of minutes for a call

and calculates and prints the cost of the call


Expert's answer

#include <stdio.h>

double calc_cost(int minutes) {
  // todo write logic
  return 0.0;
}

int main() {
  int minutes;
  printf("Enter the amount of minutes for a call: ");
  scanf("%d", &minutes);
  printf("Cost for a call is %f", calc_cost(minutes));
  return 0;
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

LATEST TUTORIALS
APPROVED BY CLIENTS