using circular link list by using class
Class Employee
Eid integer ;
Ename string;
Esalary real ;
Edesignation string ;
how we can do following operation:
Create a link list
Insert a node after a specific node with a given Eid
Insert a node before a specific node with a given Eid
Edit any field of a specific node with a given Eid
Delete a specific node with the given Eid
Delete the complete link list
Reverse the link list
Swapping of specific nodes with given Eid’s
Searching a specific node with the given Eid in the link list
Display the link list
Display only those employees whose salary is more than 15,000
Display only those employees whose id is odd numbered
Display only manager records.

Recommended Answers

All 3 Replies

the class declaration is almost like the struct...

typedef int ListItemType; // This is not a template class!

class SortedList
// constructor:

// SortedList operations:
   bool isEmpty() const

   int size;

   //linked list class for storing list
   class Node{
       ListItemType info;
       Node* next;
   typedef Node* nodePtr;
   nodePtr Head, Tail;

this is all I will give you, the rest is up to you

i didnt get it

well ur asking for ALOT when you arn't doing any of your own work or atleast giving it a try. start by learning how to make the struct Node{ Node*next...and all that} then once you do that change it into a class. google up some stuff or use ur book

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.