Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "My Header.h"
- void push(stackEntry myData, stack *y){
- struct node *x;
- x = malloc(sizeof(struct node));
- if (x==NULL){
- printf("Error No Space available for node\n");
- exit(1);
- }else{
- x->entry = myData;
- x->next = y->top;
- y->top = x;
- }
- }
Add Comment
Please, Sign In to add comment