Language: C

#include<stdio.h>
#include<string.h>
#include<string.h>
void init();//??????????????????
void insert();//??????????????????
struct Node* listSearch(int );
void deleteNode(struct Node *);
void deleteFirst();
void deleteLast();
void deleteKey(int );
void print();

struct Node{
 
  int key;
  struct Node *prev;
  struct Node *next;

};

struct Node *NIL = NULL;

int main(){
  int main(){

    int sumcommand , i ,key;
    char command[10];

    init();

    scanf("%d",sumcommand);

    for(i = 0; i < sumcommand ; i++){
      scanf("%s",command);
      if((strcmp("insert",command)) == 0){
	scanf("%d",&key);
	insert(key);
      }
      else if((strcmp("delete",command)) == 0){

	scanf("%d",&key);
	deleteKey(key);
      }
      else if((strcmp("deleteFirst",command)) == 0){
	deleteFirst();
      }
    }
    print();
    return 0;
  }
  void init(){

    NIL = (struct Node *)malloc(sizeof(struct Node));
    NIL->next = NIL;
    NIL->prev = NIL;

  }

  void insert(int key){
    struct Node *x =(struct Node*)malloc(sizeof(struct Node));

    x -> key = key;
    x -> next = NIL -> next;
    x -> next -> prev = x;

    NIL -> next = x;

    x -> prev = NIL;
  }
  struct Node* listSearch(int key){  
struct Node *y = NIL -> next;

  while(y != NIL && y -> key != key){
    y = y -> next;
  }
  return y;
  }
  void deleteNode(struct Node *x){
    if(x == NIL){
      return ;
    }
    x -> prev -> next = x -> next;
    x -> next -> prev = x -> prev;

    free(x);
  }

  void deleteFirst(){
    deleteNode(NIL -> next);
  }
  void deleteLast(){
    deleteNode(NIL -> prev);
  }
  void( deleteKey(int key){
      deleteNode(listSearch(key));
    }
    void print(){
      struct Node *z = NIL -> next;
      int x;
      while(1){
	if(z == NIL){
	  break;
	}
	if(x++ > 0){
	  prinf(" ");
	}
	print("%d",z -> key);
	z = z -> next;
      }
      printf("\n");
    }

Compiler output:
main.c: In function 'init':
main.c:53:26: error: implicit declaration of function 'malloc' [-Wimplicit-function-declaration]
   53 |     NIL = (struct Node *)malloc(sizeof(struct Node));
      |                          ^~~~~~
main.c:3:1: note: include '<stdlib.h>' or provide a declaration of 'malloc'
    2 | #include<string.h>
  +++ |+#include <stdlib.h>
    3 | #include<string.h>
main.c:53:26: warning: incompatible implicit declaration of built-in function 'malloc' [-Wbuiltin-declaration-mismatch]
   53 |     NIL = (struct Node *)malloc(sizeof(struct Node));
      |                          ^~~~~~
main.c:53:26: note: include '<stdlib.h>' or provide a declaration of 'malloc'
main.c: In function 'insert':
main.c:60:35: warning: incompatible implicit declaration of built-in function 'malloc' [-Wbuiltin-declaration-mismatch]
   60 |     struct Node *x =(struct Node*)malloc(sizeof(struct Node));
      |                                   ^~~~~~
main.c:60:35: note: include '<stdlib.h>' or provide a declaration of 'malloc'
main.c: In function 'deleteNode':
main.c:85:5: error: implicit declaration of function 'free' [-Wimplicit-function-declaration]
   85 |     free(x);
      |     ^~~~
main.c:85:5: note: include '<stdlib.h>' or provide a declaration of 'free'
main.c:85:5: warning: incompatible implicit declaration of built-in function 'free' [-Wbuiltin-declaration-mismatch]
main.c:85:5: note: include '<stdlib.h>' or provide a declaration of 'free'
main.c: In function 'main':
main.c:94:27: error: expected ')' before '{' token
   94 |   void( deleteKey(int key){
      |                           ^
      |                           )
main.c:111:5: error: expected declaration or statement at end of input
  111 |     }
      |     ^