passing structure to function in c language
Advertisements can anyone help? why ‘&’ is not required while calling a function in this program? but is thought that ‘&’ is required in call by reference. #include <stdio.h> #include <stdlib.h> struct node{ int data; struct node *next; }; void traversal(struct node *ptr) { while(ptr!=NULL) { printf("%d\n", ptr->data); ptr = ptr->next; } } int main()… Read More passing structure to function in c language