Home C C++ Java Python Perl PHP SQL JavaScript Linux Selenium QT Online Test

Home » Forum » x-Forum » Question

please help me i am going to crazy why am i getting 0 exce

#include<stdio.h>
#include<stdlib.h>
#include<math.h>

int get_problem();
void get_rate_drop_factor ();
void get_kg_rate_conc();
void get_units_conc();
float fig_drops_min (float * ,float *);
float fig_ml_hr (float *);
float by_weight (float *, float *, float *);
float by_units (float * ,float *);

int main()
{

float rate;
float dropfactor;
float hours;
float weight;
float concentration;
int choice;


do{

choice = get_problem ();
switch(choice)
{
case 1:
{
get_rate_drop_factor ();

printf("The drop rate per minute is: %f ",fig_drops_min(&rate,&dropfactor));
}

break;
case 2:
printf("Enter number of hours: ");
scanf("%f",&hours);
printf("\nThe rate in milliliters per hour is: %f",fig_ml_hr(&hours));
break;

case 3:
get_kg_rate_conc ();
printf("The rate in millimeters per hour is: %f",by_weight);
break;
case 4:
get_units_conc();
printf("The rate in millimeters per hour is: %f ",by_units);


break;

case 5:
break;
}
}while (choice < 5);

return 0;
}

int get_problem ()
{
int choice;
printf("\nEnter the number of the problem you wish to solve.");
printf("\tGIVEN A MEDICAL ORDER IN\tCALCULATE RATE IN\n");
printf("(1)ml/hr & tubing drop factor\t\tdrops/min");
printf("(2) 1L for n hr\t\t\t\tml/hr");
printf("(3) mg/kg/hr & concentration in mg/ml\tml/hr");
printf("(4) units/hr &concentration in units/m1 mi/hr");
printf("(5) QUIT\n\n");
printf("Problem=>");
scanf("%d",&choice);
return choice;
}

Posted by barisgvrcn 2020-11-23 10:13:45

No Ans Posted

Please login to comment

Log In


Ask New Question