SlideShare a Scribd company logo
#include
#include
#include
/*
* Node Declaration
*/
using namespace std;
struct node
{
int info;
struct node *next;
struct node *prev;
}*start;
/*
Class Declaration
*/
class double_llist
{
public:
void create_list(int value);
void add_begin(int value);
void add_after(int value, int position);
void delete_element(int value);
void search_element(int value);
void display_dlist();
void count();
void reverse();
double_llist()
{
start = NULL;
}
};
/*
* Main: Conatins Menu
*/
int main()
{
int choice, element, position;
double_llist dl;
while (1)
{
cout<>choice;
switch ( choice )
{
case 1:
cout<<"Enter the element: ";
cin>>element;
dl.create_list(element);
cout<>element;
dl.add_begin(element);
cout<>element;
cout<<"Insert Element after postion: ";
cin>>position;
dl.add_after(element, position);
cout<>element;
dl.delete_element(element);
cout<info = value;
temp->next = NULL;
if (start == NULL)
{
temp->prev = NULL;
start = temp;
}
else
{
s = start;
while (s->next != NULL)
s = s->next;
s->next = temp;
temp->prev = s;
}
}
/*
* Insertion at the beginning
*/
void double_llist::add_begin(int value)
{
if (start == NULL)
{
cout<<"First Create the list."<prev = NULL;
temp->info = value;
temp->next = start;
start->prev = temp;
start = temp;
cout<<"Element Inserted"<next;
if (q == NULL)
{
cout<<"There are less than ";
cout<info = value;
if (q->next == NULL)
{
q->next = tmp;
tmp->next = NULL;
tmp->prev = q;
}
else
{
tmp->next = q->next;
tmp->next->prev = tmp;
q->next = tmp;
tmp->prev = q;
}
cout<<"Element Inserted"<info == value)
{
tmp = start;
start = start->next;
start->prev = NULL;
cout<<"Element Deleted"<next->next != NULL)
{
/*Element deleted in between*/
if (q->next->info == value)
{
tmp = q->next;
q->next = tmp->next;
tmp->next->prev = q;
cout<<"Element Deleted"<next;
}
/*last element deleted*/
if (q->next->info == value)
{
tmp = q->next;
free(tmp);
q->next = NULL;
cout<<"Element Deleted"<info<<" <-> ";
q = q->next;
}
cout<<"NULL"<next;
cnt++;
}
cout<<"Number of elements are: "<next;
p1->next = NULL;
p1->prev = p2;
while (p2 != NULL)
{
p2->prev = p2->next;
p2->next = p1;
p1 = p2;
p2 = p2->prev;
}
start = p1;
cout<<"List Reversed"<
Solution
#include
#include
#include
/*
* Node Declaration
*/
using namespace std;
struct node
{
int info;
struct node *next;
struct node *prev;
}*start;
/*
Class Declaration
*/
class double_llist
{
public:
void create_list(int value);
void add_begin(int value);
void add_after(int value, int position);
void delete_element(int value);
void search_element(int value);
void display_dlist();
void count();
void reverse();
double_llist()
{
start = NULL;
}
};
/*
* Main: Conatins Menu
*/
int main()
{
int choice, element, position;
double_llist dl;
while (1)
{
cout<>choice;
switch ( choice )
{
case 1:
cout<<"Enter the element: ";
cin>>element;
dl.create_list(element);
cout<>element;
dl.add_begin(element);
cout<>element;
cout<<"Insert Element after postion: ";
cin>>position;
dl.add_after(element, position);
cout<>element;
dl.delete_element(element);
cout<info = value;
temp->next = NULL;
if (start == NULL)
{
temp->prev = NULL;
start = temp;
}
else
{
s = start;
while (s->next != NULL)
s = s->next;
s->next = temp;
temp->prev = s;
}
}
/*
* Insertion at the beginning
*/
void double_llist::add_begin(int value)
{
if (start == NULL)
{
cout<<"First Create the list."<prev = NULL;
temp->info = value;
temp->next = start;
start->prev = temp;
start = temp;
cout<<"Element Inserted"<next;
if (q == NULL)
{
cout<<"There are less than ";
cout<info = value;
if (q->next == NULL)
{
q->next = tmp;
tmp->next = NULL;
tmp->prev = q;
}
else
{
tmp->next = q->next;
tmp->next->prev = tmp;
q->next = tmp;
tmp->prev = q;
}
cout<<"Element Inserted"<info == value)
{
tmp = start;
start = start->next;
start->prev = NULL;
cout<<"Element Deleted"<next->next != NULL)
{
/*Element deleted in between*/
if (q->next->info == value)
{
tmp = q->next;
q->next = tmp->next;
tmp->next->prev = q;
cout<<"Element Deleted"<next;
}
/*last element deleted*/
if (q->next->info == value)
{
tmp = q->next;
free(tmp);
q->next = NULL;
cout<<"Element Deleted"<info<<" <-> ";
q = q->next;
}
cout<<"NULL"<next;
cnt++;
}
cout<<"Number of elements are: "<next;
p1->next = NULL;
p1->prev = p2;
while (p2 != NULL)
{
p2->prev = p2->next;
p2->next = p1;
p1 = p2;
p2 = p2->prev;
}
start = p1;
cout<<"List Reversed"<

More Related Content

Similar to #includeiostream#includecstdio#includecstdlib Node .pdf

#include iostream #includeData.h #includePerson.h#in.pdf
#include iostream #includeData.h #includePerson.h#in.pdf#include iostream #includeData.h #includePerson.h#in.pdf
#include iostream #includeData.h #includePerson.h#in.pdf
annucommunication1
ย 
Write a program to implement below operations with both singly and d.pdf
Write a program to implement below operations with both singly and d.pdfWrite a program to implement below operations with both singly and d.pdf
Write a program to implement below operations with both singly and d.pdf
thangarajarivukadal
ย 
Ds 2 cycle
Ds 2 cycleDs 2 cycle
Ds 2 cycle
Chaitanya Kn
ย 
using set identitiesSolutionimport java.util.Scanner; c.pdf
using set identitiesSolutionimport java.util.Scanner;  c.pdfusing set identitiesSolutionimport java.util.Scanner;  c.pdf
using set identitiesSolutionimport java.util.Scanner; c.pdf
excellentmobilesabc
ย 
mainpublic class AssignmentThree { ย ย  public static void ma.pdf
mainpublic class AssignmentThree { ย ย  public static void ma.pdfmainpublic class AssignmentThree { ย ย  public static void ma.pdf
mainpublic class AssignmentThree { ย ย  public static void ma.pdf
fathimafancyjeweller
ย 
I need help implementing a Stack with this java programming assignme.pdf
I need help implementing a Stack with this java programming assignme.pdfI need help implementing a Stack with this java programming assignme.pdf
I need help implementing a Stack with this java programming assignme.pdf
sauravmanwanicp
ย 
Consider L = {a^nb^2nc^P p 0}. Prove L is not a context-free langu.pdf
Consider L = {a^nb^2nc^P  p  0}. Prove L is not a context-free langu.pdfConsider L = {a^nb^2nc^P  p  0}. Prove L is not a context-free langu.pdf
Consider L = {a^nb^2nc^P p 0}. Prove L is not a context-free langu.pdf
bharatchawla141
ย 
tested on eclipseDoublyLinkedList class.pdf
tested on eclipseDoublyLinkedList class.pdftested on eclipseDoublyLinkedList class.pdf
tested on eclipseDoublyLinkedList class.pdf
shanki7
ย 
Please need help on following program using c++ language. Please inc.pdf
Please need help on following program using c++ language. Please inc.pdfPlease need help on following program using c++ language. Please inc.pdf
Please need help on following program using c++ language. Please inc.pdf
nitinarora01
ย 
Computer_Practicals-file.doc.pdf
Computer_Practicals-file.doc.pdfComputer_Practicals-file.doc.pdf
Computer_Practicals-file.doc.pdf
HIMANSUKUMAR12
ย 
Class โ€˜incrementโ€™
Class โ€˜incrementโ€™Class โ€˜incrementโ€™
Class โ€˜incrementโ€™
Syed Zaid Irshad
ย 
#include &lt;stdio.h&gt; #include &lt;malloc.h&gt; #define ISEMP.pdf
#include &lt;stdio.h&gt; #include &lt;malloc.h&gt; #define ISEMP.pdf#include &lt;stdio.h&gt; #include &lt;malloc.h&gt; #define ISEMP.pdf
#include &lt;stdio.h&gt; #include &lt;malloc.h&gt; #define ISEMP.pdf
harihelectronicspune
ย 
Help please!!(Include your modified DList.java source code file in.pdf
Help please!!(Include your modified DList.java source code file in.pdfHelp please!!(Include your modified DList.java source code file in.pdf
Help please!!(Include your modified DList.java source code file in.pdf
jyothimuppasani1
ย 
I cant find the error in which my double linked list wont display .pdf
I cant find the error in which my double linked list wont display .pdfI cant find the error in which my double linked list wont display .pdf
I cant find the error in which my double linked list wont display .pdf
allystraders
ย 
This is the main file include itemh include itemList.pdf
This is the main file include itemh include itemList.pdfThis is the main file include itemh include itemList.pdf
This is the main file include itemh include itemList.pdf
info334223
ย 
C program to insert a node in doubly linked list
C program to insert a node in doubly linked listC program to insert a node in doubly linked list
C program to insert a node in doubly linked list
Sourav Gayen
ย 
Lecture 3, c++(complete reference,herbet sheidt)chapter-13
Lecture 3, c++(complete reference,herbet sheidt)chapter-13Lecture 3, c++(complete reference,herbet sheidt)chapter-13
Lecture 3, c++(complete reference,herbet sheidt)chapter-13
Abu Saleh
ย 
Given BinaryNode.javapackage util;import java.util.;T.pdf
Given BinaryNode.javapackage util;import java.util.;T.pdfGiven BinaryNode.javapackage util;import java.util.;T.pdf
Given BinaryNode.javapackage util;import java.util.;T.pdf
Conint29
ย 
C# labprograms
C# labprogramsC# labprograms
C# labprograms
Jafar Nesargi
ย 
ItemNodeh include ltiostreamgt include ltstring.pdf
ItemNodeh    include ltiostreamgt include ltstring.pdfItemNodeh    include ltiostreamgt include ltstring.pdf
ItemNodeh include ltiostreamgt include ltstring.pdf
acmefit
ย 

Similar to #includeiostream#includecstdio#includecstdlib Node .pdf (20)

#include iostream #includeData.h #includePerson.h#in.pdf
#include iostream #includeData.h #includePerson.h#in.pdf#include iostream #includeData.h #includePerson.h#in.pdf
#include iostream #includeData.h #includePerson.h#in.pdf
ย 
Write a program to implement below operations with both singly and d.pdf
Write a program to implement below operations with both singly and d.pdfWrite a program to implement below operations with both singly and d.pdf
Write a program to implement below operations with both singly and d.pdf
ย 
Ds 2 cycle
Ds 2 cycleDs 2 cycle
Ds 2 cycle
ย 
using set identitiesSolutionimport java.util.Scanner; c.pdf
using set identitiesSolutionimport java.util.Scanner;  c.pdfusing set identitiesSolutionimport java.util.Scanner;  c.pdf
using set identitiesSolutionimport java.util.Scanner; c.pdf
ย 
mainpublic class AssignmentThree { ย ย  public static void ma.pdf
mainpublic class AssignmentThree { ย ย  public static void ma.pdfmainpublic class AssignmentThree { ย ย  public static void ma.pdf
mainpublic class AssignmentThree { ย ย  public static void ma.pdf
ย 
I need help implementing a Stack with this java programming assignme.pdf
I need help implementing a Stack with this java programming assignme.pdfI need help implementing a Stack with this java programming assignme.pdf
I need help implementing a Stack with this java programming assignme.pdf
ย 
Consider L = {a^nb^2nc^P p 0}. Prove L is not a context-free langu.pdf
Consider L = {a^nb^2nc^P  p  0}. Prove L is not a context-free langu.pdfConsider L = {a^nb^2nc^P  p  0}. Prove L is not a context-free langu.pdf
Consider L = {a^nb^2nc^P p 0}. Prove L is not a context-free langu.pdf
ย 
tested on eclipseDoublyLinkedList class.pdf
tested on eclipseDoublyLinkedList class.pdftested on eclipseDoublyLinkedList class.pdf
tested on eclipseDoublyLinkedList class.pdf
ย 
Please need help on following program using c++ language. Please inc.pdf
Please need help on following program using c++ language. Please inc.pdfPlease need help on following program using c++ language. Please inc.pdf
Please need help on following program using c++ language. Please inc.pdf
ย 
Computer_Practicals-file.doc.pdf
Computer_Practicals-file.doc.pdfComputer_Practicals-file.doc.pdf
Computer_Practicals-file.doc.pdf
ย 
Class โ€˜incrementโ€™
Class โ€˜incrementโ€™Class โ€˜incrementโ€™
Class โ€˜incrementโ€™
ย 
#include &lt;stdio.h&gt; #include &lt;malloc.h&gt; #define ISEMP.pdf
#include &lt;stdio.h&gt; #include &lt;malloc.h&gt; #define ISEMP.pdf#include &lt;stdio.h&gt; #include &lt;malloc.h&gt; #define ISEMP.pdf
#include &lt;stdio.h&gt; #include &lt;malloc.h&gt; #define ISEMP.pdf
ย 
Help please!!(Include your modified DList.java source code file in.pdf
Help please!!(Include your modified DList.java source code file in.pdfHelp please!!(Include your modified DList.java source code file in.pdf
Help please!!(Include your modified DList.java source code file in.pdf
ย 
I cant find the error in which my double linked list wont display .pdf
I cant find the error in which my double linked list wont display .pdfI cant find the error in which my double linked list wont display .pdf
I cant find the error in which my double linked list wont display .pdf
ย 
This is the main file include itemh include itemList.pdf
This is the main file include itemh include itemList.pdfThis is the main file include itemh include itemList.pdf
This is the main file include itemh include itemList.pdf
ย 
C program to insert a node in doubly linked list
C program to insert a node in doubly linked listC program to insert a node in doubly linked list
C program to insert a node in doubly linked list
ย 
Lecture 3, c++(complete reference,herbet sheidt)chapter-13
Lecture 3, c++(complete reference,herbet sheidt)chapter-13Lecture 3, c++(complete reference,herbet sheidt)chapter-13
Lecture 3, c++(complete reference,herbet sheidt)chapter-13
ย 
Given BinaryNode.javapackage util;import java.util.;T.pdf
Given BinaryNode.javapackage util;import java.util.;T.pdfGiven BinaryNode.javapackage util;import java.util.;T.pdf
Given BinaryNode.javapackage util;import java.util.;T.pdf
ย 
C# labprograms
C# labprogramsC# labprograms
C# labprograms
ย 
ItemNodeh include ltiostreamgt include ltstring.pdf
ItemNodeh    include ltiostreamgt include ltstring.pdfItemNodeh    include ltiostreamgt include ltstring.pdf
ItemNodeh include ltiostreamgt include ltstring.pdf
ย 

More from gulshan16175gs

(deftemp Animalย ย  (slot locย ย ย ย ย  (default greencouch))ย ย  (slot.pdf
(deftemp Animalย ย  (slot locย ย ย ย ย  (default greencouch))ย ย  (slot.pdf(deftemp Animalย ย  (slot locย ย ย ย ย  (default greencouch))ย ย  (slot.pdf
(deftemp Animalย ย  (slot locย ย ย ย ย  (default greencouch))ย ย  (slot.pdf
gulshan16175gs
ย 
2. The pressures of O2 and NO will be negligibleSolution 2. T.pdf
 2. The pressures of O2 and NO will be negligibleSolution 2. T.pdf 2. The pressures of O2 and NO will be negligibleSolution 2. T.pdf
2. The pressures of O2 and NO will be negligibleSolution 2. T.pdf
gulshan16175gs
ย 
# Imports# Include your imports here, if any are used. import.pdf
 # Imports# Include your imports here, if any are used. import.pdf # Imports# Include your imports here, if any are used. import.pdf
# Imports# Include your imports here, if any are used. import.pdf
gulshan16175gs
ย 
The OMe is a strong electron withdrawing group an.pdf
                     The OMe is a strong electron withdrawing group an.pdf                     The OMe is a strong electron withdrawing group an.pdf
The OMe is a strong electron withdrawing group an.pdf
gulshan16175gs
ย 
O bears three lone pairs and is bound to a H, thu.pdf
                     O bears three lone pairs and is bound to a H, thu.pdf                     O bears three lone pairs and is bound to a H, thu.pdf
O bears three lone pairs and is bound to a H, thu.pdf
gulshan16175gs
ย 
Nacl and H20 so, Salt & water .pdf
                     Nacl and H20 so, Salt & water                    .pdf                     Nacl and H20 so, Salt & water                    .pdf
Nacl and H20 so, Salt & water .pdf
gulshan16175gs
ย 
In terms of ion charge, we notice that the charge.pdf
                     In terms of ion charge, we notice that the charge.pdf                     In terms of ion charge, we notice that the charge.pdf
In terms of ion charge, we notice that the charge.pdf
gulshan16175gs
ย 
Here are four characteristics of acid a) A char.pdf
                     Here are four characteristics of acid  a) A char.pdf                     Here are four characteristics of acid  a) A char.pdf
Here are four characteristics of acid a) A char.pdf
gulshan16175gs
ย 
Fe^3+(aq)Lewis acid H2O(l)Lewis baseereyedcommu .pdf
                     Fe^3+(aq)Lewis acid H2O(l)Lewis baseereyedcommu  .pdf                     Fe^3+(aq)Lewis acid H2O(l)Lewis baseereyedcommu  .pdf
Fe^3+(aq)Lewis acid H2O(l)Lewis baseereyedcommu .pdf
gulshan16175gs
ย 
wrongSolutionwrong.pdf
wrongSolutionwrong.pdfwrongSolutionwrong.pdf
wrongSolutionwrong.pdf
gulshan16175gs
ย 
You can use the below function for linear interpolation i.e.#inclu.pdf
You can use the below function for linear interpolation i.e.#inclu.pdfYou can use the below function for linear interpolation i.e.#inclu.pdf
You can use the below function for linear interpolation i.e.#inclu.pdf
gulshan16175gs
ย 
These are the following tool to build a data model for an applicatio.pdf
These are the following tool to build a data model for an applicatio.pdfThese are the following tool to build a data model for an applicatio.pdf
These are the following tool to build a data model for an applicatio.pdf
gulshan16175gs
ย 
Copper (II) Sulfate = CuSO4 Tin (IV) Oxide = SnO2.pdf
                     Copper (II) Sulfate = CuSO4 Tin (IV) Oxide = SnO2.pdf                     Copper (II) Sulfate = CuSO4 Tin (IV) Oxide = SnO2.pdf
Copper (II) Sulfate = CuSO4 Tin (IV) Oxide = SnO2.pdf
gulshan16175gs
ย 
Water is a good solvent due to its polarity. The oxygen atom in wate.pdf
Water is a good solvent due to its polarity. The oxygen atom in wate.pdfWater is a good solvent due to its polarity. The oxygen atom in wate.pdf
Water is a good solvent due to its polarity. The oxygen atom in wate.pdf
gulshan16175gs
ย 
V. The two types of larvae found in the life cycle of Diphyllobothri.pdf
V. The two types of larvae found in the life cycle of Diphyllobothri.pdfV. The two types of larvae found in the life cycle of Diphyllobothri.pdf
V. The two types of larvae found in the life cycle of Diphyllobothri.pdf
gulshan16175gs
ย 
The tolerance has been given as +-0.05 inchSolutionThe tolera.pdf
The tolerance has been given as +-0.05 inchSolutionThe tolera.pdfThe tolerance has been given as +-0.05 inchSolutionThe tolera.pdf
The tolerance has been given as +-0.05 inchSolutionThe tolera.pdf
gulshan16175gs
ย 
The voltmeter reading indicates that Zn is the negative electrode an.pdf
The voltmeter reading indicates that Zn is the negative electrode an.pdfThe voltmeter reading indicates that Zn is the negative electrode an.pdf
The voltmeter reading indicates that Zn is the negative electrode an.pdf
gulshan16175gs
ย 
The foreign exchange market facilitates the exchange of Currencies. .pdf
The foreign exchange market facilitates the exchange of Currencies. .pdfThe foreign exchange market facilitates the exchange of Currencies. .pdf
The foreign exchange market facilitates the exchange of Currencies. .pdf
gulshan16175gs
ย 
c. defendant that the complaint lacks true facts .pdf
                     c. defendant that the complaint lacks true facts .pdf                     c. defendant that the complaint lacks true facts .pdf
c. defendant that the complaint lacks true facts .pdf
gulshan16175gs
ย 
bonde order of NO in nitrate 1.33 in nitrite is 1.pdf
                     bonde order of NO in nitrate 1.33 in nitrite is 1.pdf                     bonde order of NO in nitrate 1.33 in nitrite is 1.pdf
bonde order of NO in nitrate 1.33 in nitrite is 1.pdf
gulshan16175gs
ย 

More from gulshan16175gs (20)

(deftemp Animalย ย  (slot locย ย ย ย ย  (default greencouch))ย ย  (slot.pdf
(deftemp Animalย ย  (slot locย ย ย ย ย  (default greencouch))ย ย  (slot.pdf(deftemp Animalย ย  (slot locย ย ย ย ย  (default greencouch))ย ย  (slot.pdf
(deftemp Animalย ย  (slot locย ย ย ย ย  (default greencouch))ย ย  (slot.pdf
ย 
2. The pressures of O2 and NO will be negligibleSolution 2. T.pdf
 2. The pressures of O2 and NO will be negligibleSolution 2. T.pdf 2. The pressures of O2 and NO will be negligibleSolution 2. T.pdf
2. The pressures of O2 and NO will be negligibleSolution 2. T.pdf
ย 
# Imports# Include your imports here, if any are used. import.pdf
 # Imports# Include your imports here, if any are used. import.pdf # Imports# Include your imports here, if any are used. import.pdf
# Imports# Include your imports here, if any are used. import.pdf
ย 
The OMe is a strong electron withdrawing group an.pdf
                     The OMe is a strong electron withdrawing group an.pdf                     The OMe is a strong electron withdrawing group an.pdf
The OMe is a strong electron withdrawing group an.pdf
ย 
O bears three lone pairs and is bound to a H, thu.pdf
                     O bears three lone pairs and is bound to a H, thu.pdf                     O bears three lone pairs and is bound to a H, thu.pdf
O bears three lone pairs and is bound to a H, thu.pdf
ย 
Nacl and H20 so, Salt & water .pdf
                     Nacl and H20 so, Salt & water                    .pdf                     Nacl and H20 so, Salt & water                    .pdf
Nacl and H20 so, Salt & water .pdf
ย 
In terms of ion charge, we notice that the charge.pdf
                     In terms of ion charge, we notice that the charge.pdf                     In terms of ion charge, we notice that the charge.pdf
In terms of ion charge, we notice that the charge.pdf
ย 
Here are four characteristics of acid a) A char.pdf
                     Here are four characteristics of acid  a) A char.pdf                     Here are four characteristics of acid  a) A char.pdf
Here are four characteristics of acid a) A char.pdf
ย 
Fe^3+(aq)Lewis acid H2O(l)Lewis baseereyedcommu .pdf
                     Fe^3+(aq)Lewis acid H2O(l)Lewis baseereyedcommu  .pdf                     Fe^3+(aq)Lewis acid H2O(l)Lewis baseereyedcommu  .pdf
Fe^3+(aq)Lewis acid H2O(l)Lewis baseereyedcommu .pdf
ย 
wrongSolutionwrong.pdf
wrongSolutionwrong.pdfwrongSolutionwrong.pdf
wrongSolutionwrong.pdf
ย 
You can use the below function for linear interpolation i.e.#inclu.pdf
You can use the below function for linear interpolation i.e.#inclu.pdfYou can use the below function for linear interpolation i.e.#inclu.pdf
You can use the below function for linear interpolation i.e.#inclu.pdf
ย 
These are the following tool to build a data model for an applicatio.pdf
These are the following tool to build a data model for an applicatio.pdfThese are the following tool to build a data model for an applicatio.pdf
These are the following tool to build a data model for an applicatio.pdf
ย 
Copper (II) Sulfate = CuSO4 Tin (IV) Oxide = SnO2.pdf
                     Copper (II) Sulfate = CuSO4 Tin (IV) Oxide = SnO2.pdf                     Copper (II) Sulfate = CuSO4 Tin (IV) Oxide = SnO2.pdf
Copper (II) Sulfate = CuSO4 Tin (IV) Oxide = SnO2.pdf
ย 
Water is a good solvent due to its polarity. The oxygen atom in wate.pdf
Water is a good solvent due to its polarity. The oxygen atom in wate.pdfWater is a good solvent due to its polarity. The oxygen atom in wate.pdf
Water is a good solvent due to its polarity. The oxygen atom in wate.pdf
ย 
V. The two types of larvae found in the life cycle of Diphyllobothri.pdf
V. The two types of larvae found in the life cycle of Diphyllobothri.pdfV. The two types of larvae found in the life cycle of Diphyllobothri.pdf
V. The two types of larvae found in the life cycle of Diphyllobothri.pdf
ย 
The tolerance has been given as +-0.05 inchSolutionThe tolera.pdf
The tolerance has been given as +-0.05 inchSolutionThe tolera.pdfThe tolerance has been given as +-0.05 inchSolutionThe tolera.pdf
The tolerance has been given as +-0.05 inchSolutionThe tolera.pdf
ย 
The voltmeter reading indicates that Zn is the negative electrode an.pdf
The voltmeter reading indicates that Zn is the negative electrode an.pdfThe voltmeter reading indicates that Zn is the negative electrode an.pdf
The voltmeter reading indicates that Zn is the negative electrode an.pdf
ย 
The foreign exchange market facilitates the exchange of Currencies. .pdf
The foreign exchange market facilitates the exchange of Currencies. .pdfThe foreign exchange market facilitates the exchange of Currencies. .pdf
The foreign exchange market facilitates the exchange of Currencies. .pdf
ย 
c. defendant that the complaint lacks true facts .pdf
                     c. defendant that the complaint lacks true facts .pdf                     c. defendant that the complaint lacks true facts .pdf
c. defendant that the complaint lacks true facts .pdf
ย 
bonde order of NO in nitrate 1.33 in nitrite is 1.pdf
                     bonde order of NO in nitrate 1.33 in nitrite is 1.pdf                     bonde order of NO in nitrate 1.33 in nitrite is 1.pdf
bonde order of NO in nitrate 1.33 in nitrite is 1.pdf
ย 

Recently uploaded

Bonku-Babus-Friend by Sathyajith Ray (9)
Bonku-Babus-Friend by Sathyajith Ray  (9)Bonku-Babus-Friend by Sathyajith Ray  (9)
Bonku-Babus-Friend by Sathyajith Ray (9)
nitinpv4ai
ย 
Electric Fetus - Record Store Scavenger Hunt
Electric Fetus - Record Store Scavenger HuntElectric Fetus - Record Store Scavenger Hunt
Electric Fetus - Record Store Scavenger Hunt
RamseyBerglund
ย 
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
PECB
ย 
A Visual Guide to 1 Samuel | A Tale of Two Hearts
A Visual Guide to 1 Samuel | A Tale of Two HeartsA Visual Guide to 1 Samuel | A Tale of Two Hearts
A Visual Guide to 1 Samuel | A Tale of Two Hearts
Steve Thomason
ย 
Pharmaceutics Pharmaceuticals best of brub
Pharmaceutics Pharmaceuticals best of brubPharmaceutics Pharmaceuticals best of brub
Pharmaceutics Pharmaceuticals best of brub
danielkiash986
ย 
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UPLAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
RAHUL
ย 
Philippine Edukasyong Pantahanan at Pangkabuhayan (EPP) Curriculum
Philippine Edukasyong Pantahanan at Pangkabuhayan (EPP) CurriculumPhilippine Edukasyong Pantahanan at Pangkabuhayan (EPP) Curriculum
Philippine Edukasyong Pantahanan at Pangkabuhayan (EPP) Curriculum
MJDuyan
ย 
A Independรชncia da Amรฉrica Espanhola LAPBOOK.pdf
A Independรชncia da Amรฉrica Espanhola LAPBOOK.pdfA Independรชncia da Amรฉrica Espanhola LAPBOOK.pdf
A Independรชncia da Amรฉrica Espanhola LAPBOOK.pdf
Jean Carlos Nunes Paixรฃo
ย 
Temple of Asclepius in Thrace. Excavation results
Temple of Asclepius in Thrace. Excavation resultsTemple of Asclepius in Thrace. Excavation results
Temple of Asclepius in Thrace. Excavation results
Krassimira Luka
ย 
Prรฉsentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
Prรฉsentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptxPrรฉsentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
Prรฉsentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
siemaillard
ย 
How to deliver Powerpoint Presentations.pptx
How to deliver Powerpoint  Presentations.pptxHow to deliver Powerpoint  Presentations.pptx
How to deliver Powerpoint Presentations.pptx
HajraNaeem15
ย 
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptxPengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Fajar Baskoro
ย 
Gender and Mental Health - Counselling and Family Therapy Applications and In...
Gender and Mental Health - Counselling and Family Therapy Applications and In...Gender and Mental Health - Counselling and Family Therapy Applications and In...
Gender and Mental Health - Counselling and Family Therapy Applications and In...
PsychoTech Services
ย 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
GeorgeMilliken2
ย 
Benner "Expanding Pathways to Publishing Careers"
Benner "Expanding Pathways to Publishing Careers"Benner "Expanding Pathways to Publishing Careers"
Benner "Expanding Pathways to Publishing Careers"
National Information Standards Organization (NISO)
ย 
Chapter wise All Notes of First year Basic Civil Engineering.pptx
Chapter wise All Notes of First year Basic Civil Engineering.pptxChapter wise All Notes of First year Basic Civil Engineering.pptx
Chapter wise All Notes of First year Basic Civil Engineering.pptx
Denish Jangid
ย 
Stack Memory Organization of 8086 Microprocessor
Stack Memory Organization of 8086 MicroprocessorStack Memory Organization of 8086 Microprocessor
Stack Memory Organization of 8086 Microprocessor
JomonJoseph58
ย 
Traditional Musical Instruments of Arunachal Pradesh and Uttar Pradesh - RAYH...
Traditional Musical Instruments of Arunachal Pradesh and Uttar Pradesh - RAYH...Traditional Musical Instruments of Arunachal Pradesh and Uttar Pradesh - RAYH...
Traditional Musical Instruments of Arunachal Pradesh and Uttar Pradesh - RAYH...
imrankhan141184
ย 
Bร€I TแบฌP Bแป” TRแปข TIแบพNG ANH LแปšP 9 Cแบข Nฤ‚M - GLOBAL SUCCESS - Nฤ‚M HแปŒC 2024-2025 - ...
Bร€I TแบฌP Bแป” TRแปข TIแบพNG ANH LแปšP 9 Cแบข Nฤ‚M - GLOBAL SUCCESS - Nฤ‚M HแปŒC 2024-2025 - ...Bร€I TแบฌP Bแป” TRแปข TIแบพNG ANH LแปšP 9 Cแบข Nฤ‚M - GLOBAL SUCCESS - Nฤ‚M HแปŒC 2024-2025 - ...
Bร€I TแบฌP Bแป” TRแปข TIแบพNG ANH LแปšP 9 Cแบข Nฤ‚M - GLOBAL SUCCESS - Nฤ‚M HแปŒC 2024-2025 - ...
Nguyen Thanh Tu Collection
ย 
Jemison, MacLaughlin, and Majumder "Broadening Pathways for Editors and Authors"
Jemison, MacLaughlin, and Majumder "Broadening Pathways for Editors and Authors"Jemison, MacLaughlin, and Majumder "Broadening Pathways for Editors and Authors"
Jemison, MacLaughlin, and Majumder "Broadening Pathways for Editors and Authors"
National Information Standards Organization (NISO)
ย 

Recently uploaded (20)

Bonku-Babus-Friend by Sathyajith Ray (9)
Bonku-Babus-Friend by Sathyajith Ray  (9)Bonku-Babus-Friend by Sathyajith Ray  (9)
Bonku-Babus-Friend by Sathyajith Ray (9)
ย 
Electric Fetus - Record Store Scavenger Hunt
Electric Fetus - Record Store Scavenger HuntElectric Fetus - Record Store Scavenger Hunt
Electric Fetus - Record Store Scavenger Hunt
ย 
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ย 
A Visual Guide to 1 Samuel | A Tale of Two Hearts
A Visual Guide to 1 Samuel | A Tale of Two HeartsA Visual Guide to 1 Samuel | A Tale of Two Hearts
A Visual Guide to 1 Samuel | A Tale of Two Hearts
ย 
Pharmaceutics Pharmaceuticals best of brub
Pharmaceutics Pharmaceuticals best of brubPharmaceutics Pharmaceuticals best of brub
Pharmaceutics Pharmaceuticals best of brub
ย 
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UPLAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
ย 
Philippine Edukasyong Pantahanan at Pangkabuhayan (EPP) Curriculum
Philippine Edukasyong Pantahanan at Pangkabuhayan (EPP) CurriculumPhilippine Edukasyong Pantahanan at Pangkabuhayan (EPP) Curriculum
Philippine Edukasyong Pantahanan at Pangkabuhayan (EPP) Curriculum
ย 
A Independรชncia da Amรฉrica Espanhola LAPBOOK.pdf
A Independรชncia da Amรฉrica Espanhola LAPBOOK.pdfA Independรชncia da Amรฉrica Espanhola LAPBOOK.pdf
A Independรชncia da Amรฉrica Espanhola LAPBOOK.pdf
ย 
Temple of Asclepius in Thrace. Excavation results
Temple of Asclepius in Thrace. Excavation resultsTemple of Asclepius in Thrace. Excavation results
Temple of Asclepius in Thrace. Excavation results
ย 
Prรฉsentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
Prรฉsentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptxPrรฉsentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
Prรฉsentationvvvvvvvvvvvvvvvvvvvvvvvvvvvv2.pptx
ย 
How to deliver Powerpoint Presentations.pptx
How to deliver Powerpoint  Presentations.pptxHow to deliver Powerpoint  Presentations.pptx
How to deliver Powerpoint Presentations.pptx
ย 
Pengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptxPengantar Penggunaan Flutter - Dart programming language1.pptx
Pengantar Penggunaan Flutter - Dart programming language1.pptx
ย 
Gender and Mental Health - Counselling and Family Therapy Applications and In...
Gender and Mental Health - Counselling and Family Therapy Applications and In...Gender and Mental Health - Counselling and Family Therapy Applications and In...
Gender and Mental Health - Counselling and Family Therapy Applications and In...
ย 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
ย 
Benner "Expanding Pathways to Publishing Careers"
Benner "Expanding Pathways to Publishing Careers"Benner "Expanding Pathways to Publishing Careers"
Benner "Expanding Pathways to Publishing Careers"
ย 
Chapter wise All Notes of First year Basic Civil Engineering.pptx
Chapter wise All Notes of First year Basic Civil Engineering.pptxChapter wise All Notes of First year Basic Civil Engineering.pptx
Chapter wise All Notes of First year Basic Civil Engineering.pptx
ย 
Stack Memory Organization of 8086 Microprocessor
Stack Memory Organization of 8086 MicroprocessorStack Memory Organization of 8086 Microprocessor
Stack Memory Organization of 8086 Microprocessor
ย 
Traditional Musical Instruments of Arunachal Pradesh and Uttar Pradesh - RAYH...
Traditional Musical Instruments of Arunachal Pradesh and Uttar Pradesh - RAYH...Traditional Musical Instruments of Arunachal Pradesh and Uttar Pradesh - RAYH...
Traditional Musical Instruments of Arunachal Pradesh and Uttar Pradesh - RAYH...
ย 
Bร€I TแบฌP Bแป” TRแปข TIแบพNG ANH LแปšP 9 Cแบข Nฤ‚M - GLOBAL SUCCESS - Nฤ‚M HแปŒC 2024-2025 - ...
Bร€I TแบฌP Bแป” TRแปข TIแบพNG ANH LแปšP 9 Cแบข Nฤ‚M - GLOBAL SUCCESS - Nฤ‚M HแปŒC 2024-2025 - ...Bร€I TแบฌP Bแป” TRแปข TIแบพNG ANH LแปšP 9 Cแบข Nฤ‚M - GLOBAL SUCCESS - Nฤ‚M HแปŒC 2024-2025 - ...
Bร€I TแบฌP Bแป” TRแปข TIแบพNG ANH LแปšP 9 Cแบข Nฤ‚M - GLOBAL SUCCESS - Nฤ‚M HแปŒC 2024-2025 - ...
ย 
Jemison, MacLaughlin, and Majumder "Broadening Pathways for Editors and Authors"
Jemison, MacLaughlin, and Majumder "Broadening Pathways for Editors and Authors"Jemison, MacLaughlin, and Majumder "Broadening Pathways for Editors and Authors"
Jemison, MacLaughlin, and Majumder "Broadening Pathways for Editors and Authors"
ย 

#includeiostream#includecstdio#includecstdlib Node .pdf

  • 1. #include #include #include /* * Node Declaration */ using namespace std; struct node { int info; struct node *next; struct node *prev; }*start; /* Class Declaration */ class double_llist { public: void create_list(int value); void add_begin(int value); void add_after(int value, int position); void delete_element(int value); void search_element(int value); void display_dlist(); void count(); void reverse(); double_llist() { start = NULL; } }; /* * Main: Conatins Menu */
  • 2. int main() { int choice, element, position; double_llist dl; while (1) { cout<>choice; switch ( choice ) { case 1: cout<<"Enter the element: "; cin>>element; dl.create_list(element); cout<>element; dl.add_begin(element); cout<>element; cout<<"Insert Element after postion: "; cin>>position; dl.add_after(element, position); cout<>element; dl.delete_element(element); cout<info = value; temp->next = NULL; if (start == NULL) { temp->prev = NULL; start = temp; } else { s = start; while (s->next != NULL) s = s->next; s->next = temp; temp->prev = s; }
  • 3. } /* * Insertion at the beginning */ void double_llist::add_begin(int value) { if (start == NULL) { cout<<"First Create the list."<prev = NULL; temp->info = value; temp->next = start; start->prev = temp; start = temp; cout<<"Element Inserted"<next; if (q == NULL) { cout<<"There are less than "; cout<info = value; if (q->next == NULL) { q->next = tmp; tmp->next = NULL; tmp->prev = q; } else { tmp->next = q->next; tmp->next->prev = tmp; q->next = tmp; tmp->prev = q; } cout<<"Element Inserted"<info == value) { tmp = start; start = start->next;
  • 4. start->prev = NULL; cout<<"Element Deleted"<next->next != NULL) { /*Element deleted in between*/ if (q->next->info == value) { tmp = q->next; q->next = tmp->next; tmp->next->prev = q; cout<<"Element Deleted"<next; } /*last element deleted*/ if (q->next->info == value) { tmp = q->next; free(tmp); q->next = NULL; cout<<"Element Deleted"<info<<" <-> "; q = q->next; } cout<<"NULL"<next; cnt++; } cout<<"Number of elements are: "<next; p1->next = NULL; p1->prev = p2; while (p2 != NULL) { p2->prev = p2->next; p2->next = p1; p1 = p2; p2 = p2->prev; } start = p1; cout<<"List Reversed"< Solution
  • 5. #include #include #include /* * Node Declaration */ using namespace std; struct node { int info; struct node *next; struct node *prev; }*start; /* Class Declaration */ class double_llist { public: void create_list(int value); void add_begin(int value); void add_after(int value, int position); void delete_element(int value); void search_element(int value); void display_dlist(); void count(); void reverse(); double_llist() { start = NULL; } }; /* * Main: Conatins Menu */
  • 6. int main() { int choice, element, position; double_llist dl; while (1) { cout<>choice; switch ( choice ) { case 1: cout<<"Enter the element: "; cin>>element; dl.create_list(element); cout<>element; dl.add_begin(element); cout<>element; cout<<"Insert Element after postion: "; cin>>position; dl.add_after(element, position); cout<>element; dl.delete_element(element); cout<info = value; temp->next = NULL; if (start == NULL) { temp->prev = NULL; start = temp; } else { s = start; while (s->next != NULL) s = s->next; s->next = temp; temp->prev = s; }
  • 7. } /* * Insertion at the beginning */ void double_llist::add_begin(int value) { if (start == NULL) { cout<<"First Create the list."<prev = NULL; temp->info = value; temp->next = start; start->prev = temp; start = temp; cout<<"Element Inserted"<next; if (q == NULL) { cout<<"There are less than "; cout<info = value; if (q->next == NULL) { q->next = tmp; tmp->next = NULL; tmp->prev = q; } else { tmp->next = q->next; tmp->next->prev = tmp; q->next = tmp; tmp->prev = q; } cout<<"Element Inserted"<info == value) { tmp = start; start = start->next;
  • 8. start->prev = NULL; cout<<"Element Deleted"<next->next != NULL) { /*Element deleted in between*/ if (q->next->info == value) { tmp = q->next; q->next = tmp->next; tmp->next->prev = q; cout<<"Element Deleted"<next; } /*last element deleted*/ if (q->next->info == value) { tmp = q->next; free(tmp); q->next = NULL; cout<<"Element Deleted"<info<<" <-> "; q = q->next; } cout<<"NULL"<next; cnt++; } cout<<"Number of elements are: "<next; p1->next = NULL; p1->prev = p2; while (p2 != NULL) { p2->prev = p2->next; p2->next = p1; p1 = p2; p2 = p2->prev; } start = p1; cout<<"List Reversed"<