Question.. :Write a program to input some integer value from the user and store them into a linked list. The
user should be presented with the following choice:
1. Insert a node in the list.
2. Delete a node from the list.
3. Display the list.
4. Quit
Rules for Insertion and deletion
Insertion and deletion of the node should follow Last in and First Out Principle i.e.; the inserted
node should get added towards the head of the list and the node to be deleted should also be
deleted from the head of the list. If an attempt is done to delete an element from an empty list,
then the program should prompt the user with an underflow error.

My code... :

Code:
#include <stdio.h>
#include <stdlib.h>

struct node
{
int data;
struct node *next;
};

int main()
{
      int n;

        printf("Select a Choice\n");
        printf("press 1 to insert a node in the list\n");
        printf("press 2 to delete a node from the lis\n");
        printf("press 3 to display the list\n");
        printf("press 4 to quit\n");

        scanf("%d", &n);
        if (n == 1);
        struct node * insert_begin(struct node *,int);
        if (n == 2);
        struct node * del_begin(struct node *);
        if(n == 3);
        void printnode(struct node *);
        if (n == 4);
        { printf("Bye\n");
          exit;
        }

}


struct node * insert_begin(struct node *l,int d)
{
        struct node *temp;
        temp=(struct node *)malloc(sizeof(struct node));
        temp->data=d;
        temp->next=l;
        l=temp;
        return temp;
}
struct node* del_begin(struct node *l)
{
        struct node *c=l;
        if(l==NULL)
        printf("List is empty\n");
        else
        l=l->next;
        free(c);
        return l;
}

void printnode(struct node *l)
{
        printf("\n");
        while(l!=NULL)
        {
        printf("%d -> ",l->data);
        l=l->next;
        }
        printf("NULL");
}



P.S : the thing is gcc isnt giving any errors..
and when i execute this..it simply says bye...!!!
and i am just a beginner in C..so please pinpoint the errors..thank you..