this code is not running although the compiler does not show any warning or error anyone can help?
//doubly linked list
#include <iostream>
using namespace std;
class doublelink
{
public:
struct node
{
node* prev;
int item;
node* next;
};
node* head;
doublelink()
{
head=NULL;
}
node* find(int index) // here the find pointer points to the node whose index number is entered
{ //and NOT TO THE NODE WHICH IS PREVIOUS TO THE NODE WHOSE NUMBER IS ENTERED
node* find_ptr;
find_ptr=head;
find_ptr->prev=NULL;
for (int i=1; i==index; i++)
{
find_ptr=find_ptr->next;
}
return find_ptr;
} // find end
void insert(int index,int item)
{
node *insert=new node;
if (index==1)
{
insert=head;
insert->item=item;
insert->prev=NULL;
insert->next=head;
head=insert;
}
if (index>1)
{
node* middle=find(index-1);
if (middle->next->next!=NULL)
{