This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| #include<queue> | |
| #include<stack> | |
| using namespace std; | |
| class Graph{ | |
| int nodes; //No of nodes in the graph | |
| int **A; //A is the adjacency matrix => the graph datastructure | |
| public: | |
| Graph(int nodes){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| #include<stack> | |
| using namespace std; | |
| class Graph{ | |
| int nodes; //No of nodes in the graph | |
| int **A; //A is the adjacency matrix => the graph datastructure | |
| int **B; | |
| public: | |
| Graph(int nodes){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| #include<stack> | |
| using namespace std; | |
| class Graph{ | |
| int nodes; //No of nodes in the graph | |
| int **A; //A is the adjacency matrix => the graph datastructure | |
| public: | |
| Graph(int nodes){ | |
| this->nodes = nodes; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| #include<queue> | |
| #include<stack> | |
| using namespace std; | |
| class Graph{ | |
| int nodes; //No of nodes in the graph | |
| int **A; //A is the adjacency matrix => the graph datastructure | |
| public: | |
| Graph(int nodes){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| #include<stack> | |
| using namespace std; | |
| class Graph{ | |
| int nodes; //No of nodes in the graph | |
| int **A; //A is the adjacency matrix => the graph datastructure | |
| public: | |
| Graph(int nodes){ | |
| this->nodes = nodes; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| using namespace std; | |
| struct item{ | |
| string name; | |
| string drink; | |
| item* next; | |
| }; | |
| class HashManager{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| #include<queue> | |
| using namespace std; | |
| class Node { | |
| public: | |
| Node(int data){ | |
| this->data = data; | |
| this->left = NULL; | |
| this->right = NULL; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| #include<stack> | |
| #include<math.h> | |
| using namespace std; | |
| class LinkedlistManager{ | |
| public: | |
| int data; | |
| LinkedlistManager* next; | |
| LinkedlistManager* previous; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| using namespace std; | |
| #define MAX_SIZE 11 | |
| // Creating a class named Queue. | |
| class Queue | |
| { | |
| private: | |
| int A[MAX_SIZE]; | |
| int front, rear; | |
| public: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include<iostream> | |
| using namespace std; | |
| template <class datatype> | |
| class QueueInterface{ | |
| public: | |
| virtual void enqueue(datatype data) = 0; | |
| virtual void dequeue() = 0; | |
| virtual bool isEmpty() = 0; | |
| virtual bool isFull(){ |