Question: Find the error in each of the following program segments and explain how to correct it:
a) double cube( float ); // function prototype cube( float number ) // function definition { return number * number * number; }
b) int random Number = s rand();
c) double y = 123.45678; int x; x = y; printf( "%f\n", (double) x );
d) double square( double number ) { double number; return number * number; }
e) int sum( int n ) { if ( 0 == n ) { return 0; } else { return n + sum( n ); } }