#include<stdio.h>
struct node
{
int date;
int num;
char name;
};
void fun(struct node *n);
main()
{
struct node n;
fun(&n);
}
void fun(struct node *n1)
{
n1->date =
10;
n1->num = 99;
n1->name =
'a';
printf("%d %d %c\n",n1->date,n1->num,n1->name);
printf("size of node = %d\n",sizeof(n1));
}
Op :
10 99 a
size of node = 4
0 comments: