Code:
header file
  struct node {
    int x;
    node *next;

    node(y, node *next) 
      : x(y), next(next) {}
  };
Code:
cpp file
List::node::node(int y, node *next) 
	:  x(y), next(next){

 node *cur=head;
	
	if(cur){
	       while(cur->next!=NULL)
	           cur=cur->next;	           
	       cur->next=next;
	       }
	else
	head=next;  
}
error
redefinition