2
Answers

Passing array to a function [pass by reference]

Photo of Kaustubh N

Kaustubh N

14y
8.6k
1
I have declared an array y[21] in main and want to pass it to a function using pass by reference
Plz tell me whats wrong in following statements..

int y[21];    //array declaration
void printfunction(int *y);    //protoype
printfunction(y);  //call

what changes are required?

Answers (2)