_ _ _ _ function2(_ _ _ _ _ _ _ _ _ _ _ );
main{
int n[]= {4, 5, 6};
int *kptr ;
kptr = function2( n ) ;
}
Fill in the blanks and you get:
int *function2( int array[ ]); or
int *function2( int *ptr );
/* parameters names can be omitted */
main{
int n[]= {4, 5, 6};
int *kptr ;
kptr = function2( n ) ;
}
Can you please tell me why its 'int *' in the function prototype, shudnt it be just 'void'? since its not returning anything? Or shudnt it just be 'int' excluding the '*', ?