C++ implementations of data structures and their utility functions.
More...
#include <bits/stdc++.h>
|
class | SinglyLinkedListNode |
| Singly Linked List Node class. Available member functions include default constructor and initialising constructor. More...
|
|
class | SinglyLinkedList |
| Singly Linked List class. Available member functions include default constructor, insert, find, deleteVal, printer and reverse. More...
|
|
class | DoublyLinkedListNode |
| Doubly Linked List Node class. Available member functions include default constructor and initialising constructor. More...
|
|
class | DoublyLinkedList |
| Doubly Linked List class. Available member functions include default constructor, insert, printer and reverse. More...
|
|
class | BSTNode |
| BST Node class. Available member functions include initialising constructor. More...
|
|
class | BinarySearchTree |
| BinarySearchTree class. Available member functions include default constructor, insert, traverse and height. More...
|
|
class | Trie |
| Trie class. Available member functions include default constructor, find, insert, checkPrefix and countPrefix. More...
|
|
class | Heap |
|
|
#define | ll long long int |
| long long int macro
|
|
#define | vi vector<int> |
| int vector macro
|
|
#define | vll vector<ll> |
| long long vector macro
|
|
C++ implementations of data structures and their utility functions.
- Author
- Sarthak Mittal (20005.nosp@m.0129.nosp@m.@iitb.nosp@m..ac..nosp@m.in)
- Version
- 1
- Date
- 2022-09-17
◆ merge()
Merge two sorted linked lists.
- Parameters
-
[in] | list1 | first list |
[in] | list2 | second list |
- Returns
- SinglyLinkedList
◆ operator<<() [1/3]
ostream& operator<< |
( |
ostream & |
out, |
|
|
const BSTNode & |
node |
|
) |
| |
Function to print a BST Node.
- Parameters
-
[in] | out | standard output stream |
[in] | node | the node to be printed |
- Returns
- ostream&
◆ operator<<() [2/3]
Function to print a Doubly Linked List Node.
- Parameters
-
[in] | out | standard output stream |
[in] | node | the node to be printed |
- Returns
- ostream&
◆ operator<<() [3/3]
Function to print a Singly Linked List Node.
- Parameters
-
[in] | out | standard output stream |
[in] | node | the node to be printed |
- Returns
- ostream&
◆ swap()
void swap |
( |
int & |
x, |
|
|
int & |
y |
|
) |
| |
Swap function.
- Parameters
-
[in] | x | first value |
[in] | y | second value |