Guest User

Untitled

a guest
Dec 10th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. #include "My Header.h"
  2.  
  3. void push(stackEntry myData, stack *y){
  4. struct node *x;
  5. x = malloc(sizeof(struct node));
  6.  
  7. if (x==NULL){
  8. printf("Error No Space available for node\n");
  9. exit(1);
  10. }else{
  11. x->entry = myData;
  12. x->next = y->top;
  13. y->top = x;
  14. }
  15. }
Add Comment
Please, Sign In to add comment