i'm trying to get the program to run (M/m)^(1/5) and its telling me
% gcc lab4.c
lab4.c: In function âspeeds_ratioâ:
lab4.c:34:20: error: expected â)â before â;â token
where in my code did I make a wrong turn? help please!!!
Code:#include <stdio.h> #include <math.h> #define one 1.0; #define five 5.0; double speeds_ratio(double M,double m); int main(void) { double Max; double min; printf("Input the max rpm.\n"); scanf("%lf",&Max); printf("Input the min rpm.\n"); scanf("%lf",&min); printf("The ratio between successive speeds of a six-speed gearbox with maximum speed %f rpm,and minimum speed %.1f rpm, is. %1f",Max,min,speeds_ratio(Max,min)); return(0); } double speeds_ratio(double M, double m) { double (speed); (speed) = pow(M/m,one/five); return(speed); }



LinkBack URL
About LinkBacks


