Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/careercup/CtCI-6th-Edition-cpp
/ functions
Functions
434 in github.com/careercup/CtCI-6th-Edition-cpp
⨍
Functions
434
◇
Types & classes
73
↓ 1 callers
Function
print_all_parentheses_internal
chapter-8-recursion-and-Dynamic-Programming/8-9-parens.cpp:4
↓ 1 callers
Method
push
Chapter-3-Stacks-and-Queues/3.2_stack_min.cpp:16
↓ 1 callers
Method
push
Chapter-3-Stacks-and-Queues/C++14/3.2-StackMin.cpp:12
↓ 1 callers
Function
quick
Ch 1.Arrays And Strings/10.Ouicksort.cpp:6
↓ 1 callers
Function
randomSelect
We use the Reservoir sampling to get a node uniformly at random, WITHOUT knowing the total number of nodes. The idea is, do a whatever order of traver
Chapter-4-tree-and-graph/4.11_random_node.cpp:44
↓ 1 callers
Function
recursive_multiply
The first method is rather simple and only add operation is used.*/
chapter-8-recursion-and-Dynamic-Programming/8.5_Recursive_Multiply.cpp:4
↓ 1 callers
Function
removeDuplicates
Method 1 space complexity O(1) time complexity O(n^2) * [removeDuplicates Remove duplicates without using extra space] * @param head [head of list]
chapter-2-Linked-Lists/2-1-remove-dups.cpp:67
↓ 1 callers
Function
removeDuplicates1
Method 2 space complexity - O(n) time complexity - O(n) * [removeDuplicates1 - Remove duplicates from the list using hash table] * @param head [head
chapter-2-Linked-Lists/2-1-remove-dups.cpp:92
↓ 1 callers
Function
removeLoop
chapter-2-Linked-Lists/2-8-loop-detection.cpp:17
↓ 1 callers
Function
rotate1
Ch 1.Arrays And Strings/7.Rotate_matrix/7.rotate_matrix.cpp:29
↓ 1 callers
Function
rotate2
Ch 1.Arrays And Strings/7.Rotate_matrix/7.rotate_matrix.cpp:39
↓ 1 callers
Function
routeBetwenNodes
Width visiting
Ch 4. Trees and Graphs/C++14/4.1-RouteBetweenNodes.cpp:13
↓ 1 callers
Function
routeBetwenNodesR
Ch 4. Trees and Graphs/C++14/4.1-RouteBetweenNodes.cpp:70
↓ 1 callers
Function
routeBetwenNodesWalker
Ch 4. Trees and Graphs/C++14/4.1-RouteBetweenNodes.cpp:51
↓ 1 callers
Function
runNFamilies
Ch 6. Math and Logic Puzzles/7.The Apocalypse/The Apocalypse.cpp:25
↓ 1 callers
Function
sumsFrom
Ch 4. Trees and Graphs/C++14/4.12-PathsWithSum.cpp:11
↓ 1 callers
Function
test
Ch 4. Trees and Graphs/C++14/4.1-RouteBetweenNodes.cpp:78
↓ 1 callers
Function
toggle
Ch 1.Arrays And Strings/4.Palindrome_Permutation/4-pallindrome-permutations.cpp:127
↓ 1 callers
Function
tohIterative
Function to implement TOH puzzle
chapter-8-recursion-and-Dynamic-Programming/8.6_Tower_of_Hanoi.cpp:72
↓ 1 callers
Method
topologicalSort
The function to do Topological Sort. It uses recursive DFS()
Chapter-4-tree-and-graph/4.7_build_order.cpp:58
↓ 1 callers
Function
treeFromArray
Ch 4. Trees and Graphs/C++14/4.2-MinimalTree.cpp:23
↓ 1 callers
Function
urlify
Ch 1.Arrays And Strings/3.URLify/URLify.cpp:17
↓ 1 callers
Method
value
Ch 7.OOD/1.Deck Of Cards/BlackJackCard.cpp:8
↓ 1 callers
Function
ways
chapter-8-recursion-and-Dynamic-Programming/8-11-Coins.cpp:5
Method
Animal
Chapter-3-Stacks-and-Queues/C++14/3.6-AnimalShelter.cpp:16
Method
BlackJackCard
Ch 7.OOD/1.Deck Of Cards/BlackJackCard.cpp:4
Method
BlackJackHand
Ch 7.OOD/1.Deck Of Cards/BlackJackHand.cpp:7
Method
Card
Ch 7.OOD/1.Deck Of Cards/card.cpp:16
Method
Cat
Chapter-3-Stacks-and-Queues/C++14/3.6-AnimalShelter.cpp:68
Method
DFS
A recursive function used by topologicalSort
Chapter-4-tree-and-graph/4.7_build_order.cpp:40
Method
Dog
Chapter-3-Stacks-and-Queues/C++14/3.6-AnimalShelter.cpp:60
Method
FixedMultiStack
Chapter-3-Stacks-and-Queues/3.1-Three-in-One/FixedMultiStack.cpp:3
Method
Graph
Constructor
Ch 4. Trees and Graphs/4-1-Route-Between-Nodes.cpp:19
Method
Graph
Implement the member functions
Chapter-4-tree-and-graph/4.7_build_order.cpp:28
Method
Iterator
Ch 4. Trees and Graphs/C++14/treenodeiterator.hpp:92
Method
IteratorBase
Ch 4. Trees and Graphs/C++14/treenodeiterator.hpp:13
Method
IteratorBase
Ch 4. Trees and Graphs/C++14/treenodeiterator.hpp:47
Method
Node
chapter-2-Linked-Lists/2-4-partition.cpp:23
Method
Node
chapter-2-Linked-Lists/2-7-intersection.cpp:15
Method
Node
chapter-2-Linked-Lists/2-2-kthToLast.cpp:27
Method
Node
chapter-2-Linked-Lists/2-8-loop-detection.cpp:14
Method
Node
chapter-2-Linked-Lists/2-3-delete-middle-node.cpp:20
Method
Node
chapter-2-Linked-Lists/2-6-palindrome.cpp:17
Method
Node
chapter-2-Linked-Lists/2-5-add-lists.cpp:27
Method
Node
Chapter-3-Stacks-and-Queues/C++14/stack.hpp:65
Method
Node
Chapter-3-Stacks-and-Queues/C++14/queue.hpp:71
Method
Node
Ch 4. Trees and Graphs/4-2-Minimal-Tree.cpp:8
Method
Node
Ch 4. Trees and Graphs/C++14/graph.hpp:34
Method
Node
Ch 4. Trees and Graphs/C++14/treenode.hpp:45
Method
NodeBase
Ch 4. Trees and Graphs/C++14/treenode.hpp:9
Method
NodeBase
Ch 4. Trees and Graphs/C++14/treenode.hpp:28
Method
Point
chapter-8-recursion-and-Dynamic-Programming/8-2-Robot-in-a-Grid.cpp:12
Method
Queue
Chapter-3-Stacks-and-Queues/C++14/queue.hpp:7
Method
RandomNode
Ch 4. Trees and Graphs/C++14/4.11m-RandomTree.cpp:25
Method
RandomNode
Ch 4. Trees and Graphs/C++14/4.11-RandomNode.cpp:35
Method
SetOfStacks
Chapter-3-Stacks-and-Queues/C++14/3.3-StackOfPlates.cpp:57
Method
SetOfStacks
Chapter-3-Stacks-and-Queues/C++14/3.3-StackOfPlatesFU.cpp:148
Method
Shelter
Chapter-3-Stacks-and-Queues/C++14/3.6-AnimalShelter.cpp:76
Method
SortedStack
Chapter-3-Stacks-and-Queues/C++14/3.5-SortStack.cpp:12
Method
Stack
Chapter-3-Stacks-and-Queues/C++14/stack.hpp:7
Method
Stack
Chapter-3-Stacks-and-Queues/3.2-Stack-Min/Stack.cpp:3
Method
StackNode
Chapter-3-Stacks-and-Queues/3.2-Stack-Min/StackNode.cpp:3
Method
Tree
Ch 4. Trees and Graphs/C++14/4.11-RandomNode.cpp:21
Method
add
Ch 4. Trees and Graphs/C++14/4.11m-RandomTree.cpp:91
Function
checkHeight
Ch 4. Trees and Graphs/4.4_Check_Balanced.cpp:1
Function
checkNode
Ch 4. Trees and Graphs/C++14/4.5-ValidateBST.cpp:8
Function
checkSubtree
Ch 4. Trees and Graphs/C++14/4.10r-CheckSubtree.cpp:19
Function
compareTrees
Ch 4. Trees and Graphs/C++14/4.10i-CheckSubtree.cpp:33
Function
compareTrees
Ch 4. Trees and Graphs/C++14/4.10r-CheckSubtree.cpp:27
Function
constainsTree
Chapter-4-tree-and-graph/4.10_check_subtree.cpp:44
Function
containTree
Ch 4. Trees and Graphs/4.10_Check_Subtree.cpp:1
Method
create
Chapter-3-Stacks-and-Queues/C++14/3.6-AnimalShelter.cpp:47
Function
createGraph
Ch 4. Trees and Graphs/C++14/graphtestutils.hpp:8
Function
createMinBST
Ch 4. Trees and Graphs/4.2_Minimal_Tree.cpp:1
Function
findCommonAncestor
Ch 4. Trees and Graphs/C++14/4.8-FirstCommonAncestor.cpp:37
Function
findCommonAncestor
Ch 4. Trees and Graphs/C++14/4.8p-FirstCommonAncestor.cpp:29
Function
findNodeFrom
Ch 4. Trees and Graphs/C++14/4.8-FirstCommonAncestor.cpp:23
Function
findSuccessor
Ch 4. Trees and Graphs/4.6_Successor.cpp:8
Method
for
Ch 7.OOD/1.Deck Of Cards/BlackJackHand.cpp:39
Function
getExampleGraph
Ch 4. Trees and Graphs/C++14/graphtestutils.hpp:20
Function
getExampleGraph2
Ch 4. Trees and Graphs/C++14/graphtestutils.hpp:27
Function
getExampleGraph3
Ch 4. Trees and Graphs/C++14/graphtestutils.hpp:34
Function
getHeight
Ch 4. Trees and Graphs/C++14/4.4-CheckBalanced.cpp:10
Function
getMin
Ch 4. Trees and Graphs/C++14/4.6-Successor.cpp:9
Method
getMinimum
Chapter-3-Stacks-and-Queues/3.2-Stack-Min/Stack.cpp:63
Method
getOrder
Chapter-3-Stacks-and-Queues/C++14/3.6-AnimalShelter.cpp:31
Function
getSampleTree
Ch 4. Trees and Graphs/C++14/treetestutils.hpp:120
Method
getSize
Chapter-3-Stacks-and-Queues/3.2-Stack-Min/Stack.cpp:79
Method
indexOfTop
Chapter-3-Stacks-and-Queues/3.1-Three-in-One/FixedMultiStack.cpp:60
Function
is21
Ch 7.OOD/1.Deck Of Cards/BlackJackHand.cpp:70
Method
isAvailable
Ch 7.OOD/1.Deck Of Cards/card.cpp:30
Function
isBalanced
Ch 4. Trees and Graphs/4.4_Check_Balanced.cpp:22
Function
isBlackJack
Ch 7.OOD/1.Deck Of Cards/BlackJackHand.cpp:75
Method
isEmpty
Chapter-3-Stacks-and-Queues/C++14/queue.hpp:54
Method
isEmpty
Chapter-3-Stacks-and-Queues/3.2-Stack-Min/Stack.cpp:74
Method
isEmpty
Chapter-3-Stacks-and-Queues/3.1-Three-in-One/FixedMultiStack.cpp:50
Method
isEmpty
Ch 4. Trees and Graphs/C++14/tree.hpp:25
Method
isFull
Chapter-3-Stacks-and-Queues/3.1-Three-in-One/FixedMultiStack.cpp:55
Function
isPermutationOfPalindrome
Ch 1.Arrays And Strings/3.Palindrome Permutation/Palindrome Permutation.cpp:53
Function
isPermutationOfPalindrome_bitwise
Ch 1.Arrays And Strings/3.Palindrome Permutation/Palindrome Permutation.cpp:59
← previous
next →
201–300 of 434, ranked by callers