Hello,everybody ! I need your help! My problem is this assignment
[CODE=c]char pnm[10];
void enqueue(int pd,char pnm[10],int pnum,int ptm,struct queue *z)
{struct node *p;
p=(struct node *)malloc(sizeof (struct node)); // give me memory such big
p->id = pd;
p->name = pnm; here is "incompatib le types in assignment" for the gcc
p->num_quant=pnum ; [/CODE]
Which is the appropiate assignment? Why?
[CODE=c]char pnm[10];
void enqueue(int pd,char pnm[10],int pnum,int ptm,struct queue *z)
{struct node *p;
p=(struct node *)malloc(sizeof (struct node)); // give me memory such big
p->id = pd;
p->name = pnm; here is "incompatib le types in assignment" for the gcc
p->num_quant=pnum ; [/CODE]
Which is the appropiate assignment? Why?
Comment