Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/VamsiSangam/theoryofprogramming
/ functions
Functions
258 in github.com/VamsiSangam/theoryofprogramming
⨍
Functions
258
◇
Types & classes
72
↓ 1 callers
Function
dijkstra
Dijkstra's Algorithm function
Graph Theory/Dijkstra's Algorithm/C/dijkstras-algorithm.c:50
↓ 1 callers
Method
dijkstra
(int[][] graph, int src)
Graph Theory/Dijkstra's Algorithm/Java/DijkstraAlgorithm.java:52
↓ 1 callers
Function
editDistance
Dynamic Programming/Edit Distance/C/edit-distance-optimised.c:27
↓ 1 callers
Function
editDistance
Dynamic Programming/Edit Distance/C/edit-distance.c:27
↓ 1 callers
Method
editDistance
(String a, String b)
Dynamic Programming/Edit Distance/Java/EditDistance.java:29
↓ 1 callers
Method
editDistance
(String a, String b)
Dynamic Programming/Edit Distance/Java/OptimisedEditDistance.java:29
↓ 1 callers
Function
enqueue
enqueues an entry into the Priority Queue
Graph Theory/Prim's Algorithm/C/prims-algorithm.c:40
↓ 1 callers
Function
extractMax
Returns the root value and deletes it by swapping the root node and the last node and then calling heapify on root node
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:239
↓ 1 callers
Function
extractMin
Removes and Returns the topmost element - O (log N)
Graph Theory/Dijkstra's Algorithm/C/dijkstras-algorithm-using-binary-heap.c:122
↓ 1 callers
Function
findLastNode
Traverses the Heap top-to-bottom once and returns the location of the last node. Works on the priciple of traversing a Binary Tree by the binary repre
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:29
↓ 1 callers
Function
getBinaryHeap
Allocates memory for the Binary Heap thus creates the root node
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:147
↓ 1 callers
Method
getChildren
()
Tree Data Structures/N-ary Tree/Java/NaryTreeNode.java:36
↓ 1 callers
Method
getIntersectingVertex
(int[] sourceParent, int[] goalParent)
Artificial Intelligence/Bidirectional Search/Java/BidirectionalSearch.java:103
↓ 1 callers
Function
getMinVertex
Retuns the vertex which is not visited and has least distance
Graph Theory/Dijkstra's Algorithm/C/dijkstras-algorithm.c:35
↓ 1 callers
Method
getPath
(int[] sourceParent, int[] goalParent, int intersectingVertex)
Artificial Intelligence/Bidirectional Search/Java/BidirectionalSearch.java:115
↓ 1 callers
Function
getSegmentTree
Allocates memory for the root and calls method to construct the Segment Tree
Tree Data Structures/Segment Trees/C/segment-tree.c:51
↓ 1 callers
Function
getSumQuery
Recursive procedure to find out the sum of elements from arr[low] to arr[high] using the Segment Tree
Tree Data Structures/Segment Trees/C/segment-tree.c:84
↓ 1 callers
Method
hasGameEnded
(int[][] game)
Artificial Intelligence/MiniMax Algorithm with Alpha-Beta Pruning/Java/MiniMaxWithAlphaBetaPruning.java:207
↓ 1 callers
Method
hasGameEnded
(int[][] game)
Artificial Intelligence/MiniMax Algorithm/Java/MiniMaxAlgorithm.java:191
↓ 1 callers
Function
heapSort
Heap Sort procedure which takes and empyt list 'Sorted List' and fills it with the elements in sorted order. Keeps extracting the maximum element from
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:282
↓ 1 callers
Function
heapify
The standard recursive Heapify procedure to convert a partial heap to a complete heap Mainly used by Extract-Max procedure
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:179
↓ 1 callers
Function
heapify
Graph Theory/Prim's Algorithm/C/prims-algorithm.c:60
↓ 1 callers
Function
inOrderTraversal
Prints the nodes of the Binary Heap in the In-Order fashion
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:165
↓ 1 callers
Function
insert
Tree Data Structures/Trie Tree/C++/trie-tree-spoj-dict.cpp:28
↓ 1 callers
Function
insertIntoHeap
Inserts a new node into the binary heap and also makes the neccessary swaps to ensure Heap Property isn't violated
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:131
↓ 1 callers
Function
insertUtil
The recursive procedure which goes top-to-bottom from the root to the place of insertion and inserts the new node with a value 'Value'. Uses binary tr
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:90
↓ 1 callers
Function
insertWord
Inserts a word 'text' into the Trie Tree 'trieTree' and marks it's occurence as 'index'.
Tree Data Structures/Trie Tree/C++/trie-tree-using-stl.cpp:31
↓ 1 callers
Function
jumpSearchUtil
Searching Algorithms/Jump Search Algorithm/C/optimised-jump-search.c:24
↓ 1 callers
Method
jumpSearchUtil
(int[] arr, int val, int low, int high)
Searching Algorithms/Jump Search Algorithm/Java/OptimisedJumpSearch.java:40
↓ 1 callers
Function
lexicographPrint
Tree Data Structures/Trie Tree/C++/trie-tree-spoj-dict.cpp:66
↓ 1 callers
Function
maxSubArray
Dynamic Programming/Kadane's Algorithm/C/kadanes-algorithm.c:14
↓ 1 callers
Method
maxSubArray
(int[] arr)
Dynamic Programming/Kadane's Algorithm/Java/KadanesAlgorithm.java:28
↓ 1 callers
Function
merge
(left, right)
Sorting Algorithms/Merge Sort Algorithm/Python/MergeSort.py:93
↓ 1 callers
Method
merge
(int[] array, int low, int mid, int high)
Sorting Algorithms/Merge Sort Algorithm/Java/MergeSort.java:63
↓ 1 callers
Function
mergePartitions
Merges two sorted partitions into a bigger sorted array
Sorting Algorithms/Merge Sort Algorithm/C/merge-sort.c:15
↓ 1 callers
Function
mergeSort
Partitions the array into two Does nothing if array has only one element
Sorting Algorithms/Merge Sort Algorithm/C/merge-sort.c:54
↓ 1 callers
Method
mergeSort
(int array[], int low, int high)
Sorting Algorithms/Merge Sort Algorithm/Java/MergeSort.java:46
↓ 1 callers
Function
mergeUsingLoops
(left, right)
Sorting Algorithms/Merge Sort Algorithm/Python/MergeSort.py:38
↓ 1 callers
Function
mergesort
(array)
Sorting Algorithms/Merge Sort Algorithm/Python/MergeSort.py:68
↓ 1 callers
Function
min
Searching Algorithms/Jump Search Algorithm/C/optimised-jump-search.c:20
↓ 1 callers
Function
min
Dynamic Programming/Edit Distance/C/edit-distance-optimised.c:16
↓ 1 callers
Function
min
Dynamic Programming/Edit Distance/C/edit-distance.c:16
↓ 1 callers
Method
minDistance
(int[] dist, boolean[] sptSet)
Graph Theory/Dijkstra's Algorithm/Java/DijkstraAlgorithm.java:24
↓ 1 callers
Method
minKey
(int[] key, boolean[] mstSet)
Graph Theory/Prim's Algorithm/Java/PrimsAlgorithm.java:24
↓ 1 callers
Method
partition
(int arr[], int low, int high)
Sorting Algorithms/Quick Sort Algorithm/Java/QuickSort.java:57
↓ 1 callers
Function
prim
Prim's Algorithm function
Graph Theory/Prim's Algorithm/C++/prims-algorithm-using-stl.cpp:36
↓ 1 callers
Function
prim
Prim's Algorithm function
Graph Theory/Prim's Algorithm/C/prims-algorithm.c:122
↓ 1 callers
Method
primMST
(int[][] graph)
Graph Theory/Prim's Algorithm/Java/PrimsAlgorithm.java:51
↓ 1 callers
Function
print
A simple utility function to aid In-Order Walk
Tree Data Structures/Binary Heaps/C++/binary-heap-using-struct.cpp:158
↓ 1 callers
Method
printMST
(int parent[], int n, int[][] graph)
Graph Theory/Prim's Algorithm/Java/PrimsAlgorithm.java:41
↓ 1 callers
Function
printNegativeCycle
Graph Theory/Bellman Ford Algorithm/C/bellman-ford.c:112
↓ 1 callers
Function
printPath
Recursively looks at a vertex's parent to print the path
Graph Theory/Dijkstra's Algorithm/C++/dijkstras-algorithm.cpp:72
↓ 1 callers
Function
printPath
Recursively looks at a vertex's parent to print the path
Graph Theory/Dijkstra's Algorithm/C/dijkstras-algorithm-using-binary-heap.c:187
↓ 1 callers
Function
printPath
Recursively looks at a vertex's parent to print the path
Graph Theory/Dijkstra's Algorithm/C/dijkstras-algorithm.c:86
↓ 1 callers
Function
printPathFromSourceToDestination
Graph Theory/Snakes and Ladders Game Code/C++/SnakesAndLadders.cpp:28
↓ 1 callers
Function
printPathFromSourceToDestination
Graph Theory/Breadth First Search Algorithm/C++/breadth-first-search-using-queue.cpp:19
↓ 1 callers
Method
printSolution
(int[] dist, int n)
Graph Theory/Dijkstra's Algorithm/Java/DijkstraAlgorithm.java:41
↓ 1 callers
Method
printUtil
(NaryTreeNode node, int depth)
Tree Data Structures/N-ary Tree/Java/NaryTreeNode.java:52
↓ 1 callers
Method
printUtil
(Node node, StringBuilder str)
Tree Data Structures/Compressed Trie Tree/Java/Trie.java:91
↓ 1 callers
Function
quickSort
Sorting Algorithms/Quick Sort Algorithm/C/quick-sort.c:14
↓ 1 callers
Method
quickSort
(int[] arr, int low, int high)
Sorting Algorithms/Quick Sort Algorithm/Java/QuickSort.java:44
↓ 1 callers
Function
quickSortDijkstra
Sorting Algorithms/Quick Sort Algorithm/C/quick-sort-dijkstra-3-way.c:14
↓ 1 callers
Method
quickSortDijsktra
(int[] array, int low, int high)
Sorting Algorithms/Quick Sort Algorithm/Java/QuickSortDijsktra.java:44
↓ 1 callers
Function
quickSortDualPivot
Sorting Algorithms/Quick Sort Algorithm/C/quick-sort-dual-pivot.c:14
↓ 1 callers
Method
quickSortDualPivot
(int[] array, int low, int high)
Sorting Algorithms/Quick Sort Algorithm/Java/QuickSortDualPivot.java:45
↓ 1 callers
Function
quickSortRandomPivot
Sorting Algorithms/Quick Sort Algorithm/C/quick-sort-random-pivot.c:15
↓ 1 callers
Method
quickSortRandomPivot
(int[] array, int low, int high)
Sorting Algorithms/Quick Sort Algorithm/Java/QuickSortRandomPivot.java:44
↓ 1 callers
Function
quick_sort
(alist)
Sorting Algorithms/Quick Sort Algorithm/Python/QuickSort.py:13
↓ 1 callers
Method
removeEdge
Removes the first occurence of an edge and returns true if there was any change in the collection, else false
Graph Theory/Adjcacency List/C#/AdjacencyList.cs:84
↓ 1 callers
Function
removeWord
Searches the word first, if not found, does nothing if found, deletes the nodes corresponding to the word
Tree Data Structures/Trie Tree/C++/trie-tree-using-stl.cpp:79
↓ 1 callers
Method
resetChildren
()
Tree Data Structures/Trie Tree/Java/Trie.java:178
↓ 1 callers
Function
searchWord
Tree Data Structures/Trie Tree/C++/trie-tree-spoj-dict.cpp:44
↓ 1 callers
Function
searchWord
Searches for the occurence of a word in 'trieTree', if not found, returns NULL, if found, returns poniter pointing to the last node of the word in the
Tree Data Structures/Trie Tree/C++/trie-tree-using-stl.cpp:56
↓ 1 callers
Method
setLeaf
(boolean leaf)
Tree Data Structures/Trie Tree/Java/Trie.java:186
↓ 1 callers
Method
solveMazeUsingBacktracking
(int[][] maze, int i, int j)
Backtracking/Maze Solver/Java/MazeSolver.java:72
↓ 1 callers
Function
updateQuery
Updates an element in the Segment Tree and makes the neccessary adjustments
Tree Data Structures/Segment Trees/C/segment-tree.c:123
Method
AdjacencyList
Constructor - creates an empty Adjacency List
Graph Theory/Adjcacency List/C#/AdjacencyList.cs:22
Method
DijkstraAlgorithm
(int vertices)
Graph Theory/Dijkstra's Algorithm/Java/DijkstraAlgorithm.java:18
Method
Graph
(int v)
Graph Theory/Breadth First Search Algorithm/Java/Graph.java:24
Method
Graph
(int v)
Graph Theory/Depth First Search Algorithm/Java/Graph.java:24
Method
Main
()
Graph Theory/Adjcacency List/C#/AdjacencyList.cs:94
Method
Move
(int i, int j)
Artificial Intelligence/MiniMax Algorithm/Java/MiniMaxAlgorithm.java:236
Method
NaryTreeNode
(String LABEL, int n)
Tree Data Structures/N-ary Tree/Java/NaryTreeNode.java:18
Method
Node
(boolean isEnd)
Tree Data Structures/Compressed Trie Tree/Java/Trie.java:174
Method
Node
(int vertex, int weight)
Graph Theory/Adjcacency List/Java/AdjacencyList.java:23
Method
Pair
(int left, int right)
Searching Algorithms/Jump Search Algorithm/Java/OptimisedJumpSearch.java:63
Method
PrimsAlgorithm
(int vertices)
Graph Theory/Prim's Algorithm/Java/PrimsAlgorithm.java:18
Method
Result
(int score, Move move)
Artificial Intelligence/MiniMax Algorithm/Java/MiniMaxAlgorithm.java:226
Method
Trie
()
Tree Data Structures/Trie Tree/Java/Trie.java:19
Method
Trie
()
Tree Data Structures/Compressed Trie Tree/Java/Trie.java:16
Method
TrieNode
()
Tree Data Structures/Trie Tree/Java/Trie.java:151
Method
addEdgeAtBegin
Adds a new Edge to the linked list from the front
Graph Theory/Adjcacency List/C#/AdjacencyList.cs:39
Method
getNumberOfVertices
Returns number of vertices Does not change for an object
Graph Theory/Adjcacency List/C#/AdjacencyList.cs:46
Function
main
Searching Algorithms/Jump Search Algorithm/C++/JumpSearch.cpp:48
Function
main
Searching Algorithms/Jump Search Algorithm/C/jump-search.c:51
Function
main
Searching Algorithms/Jump Search Algorithm/C/optimised-jump-search.c:65
Function
main
Searching Algorithms/Binary Search Algorithm/C++/binary-search.cpp:42
Function
main
Searching Algorithms/Binary Search Algorithm/C/binary-search.c:34
Function
main
Sorting Algorithms/Quick Sort Algorithm/C/quick-sort.c:62
Function
main
Sorting Algorithms/Quick Sort Algorithm/C/quick-sort-dijkstra-3-way.c:49
← previous
next →
101–200 of 258, ranked by callers