data structures using do printf("\ *****main menu*****")printf("\ push")printf("\ pop")printf("\ peek")printf("\ display")printf("\ exit")printf("\ enter your option")scanf("% "&option)switch(optioncase printf("\ enter the number to be pushed on stack")scanf("% "&val)top push(topval)breakcase top pop(top)breakcase val peek(top)if (val !- printf("\ the value at the top of stack is% "val)else printf("\ stack is empty")breakcase top display(top)break}while(option ! )return struct stack *push(struct stack *topint valstruct stack *ptrptr (struct stack*)malloc(sizeof(struct stack))ptr -data valif(top =nullptr -next nulltop ptrelse ptr -next toptop ptrreturn topstruct stack *display(struct stack *topstruct stack *ptrptr topif(top =nullprintf("\ stack is empty")else