MCPcopy Create free account

hub / github.com/black-shadows/Cracking-the-Coding-Interview / functions

Functions382 in github.com/black-shadows/Cracking-the-Coding-Interview

↓ 53 callersMethodsize
Solutions/Chapter 3 Stacks and Queues/3.5.cpp:32
↓ 28 callersMethodpush
Solutions/Chapter 3 Stacks and Queues/3.2.cpp:56
↓ 25 callersMethodtop
Solutions/Chapter 3 Stacks and Queues/3.2.cpp:62
↓ 17 callersMethodempty
* @brief Returns true if the rectangle has area zero, false otherwise. * @note Complexity: O(1) in both time and space. */
Solutions/Chapter 20 Hard/20.13.cpp:219
↓ 16 callersMethodpop
Solutions/Chapter 3 Stacks and Queues/3.2.cpp:59
↓ 12 callersMethodfront
Solutions/Chapter 3 Stacks and Queues/3.5.cpp:24
↓ 10 callersFunctioncount_one
Solutions/Chapter 5 Bit Manipulation/5.3.cpp:18
↓ 8 callersMethodempty
Solutions/Chapter 3 Stacks and Queues/3.2.cpp:65
↓ 8 callersMethodfind
Solutions/Chapter 20 Hard/hash.h:48
↓ 7 callersMethodback
Solutions/Chapter 3 Stacks and Queues/3.5.cpp:28
↓ 7 callersMethodempty
Solutions/Chapter 3 Stacks and Queues/3.5.cpp:35
↓ 7 callersMethodempty
Solutions/Chapter 3 Stacks and Queues/3.3.cpp:38
↓ 7 callersFunctionheight
Solutions/Chapter 4 Trees and Graphs/4.3.cpp:40
↓ 7 callersMethodpush
Solutions/Chapter 3 Stacks and Queues/3.5.cpp:16
↓ 6 callersMethodpush
Solutions/Chapter 3 Stacks and Queues/3.1.cpp:18
↓ 5 callersMethodinsert
Solutions/Chapter 20 Hard/hash.h:39
↓ 5 callersFunctionnegative
* @brief Computes -a using only additions (-a = a + (-2)*a). * @note Complexity: O(|a|) in time, O(1) in space. */
Solutions/Chapter 10 Mathematical/10.4.cpp:16
↓ 5 callersMethodpop
Solutions/Chapter 3 Stacks and Queues/3.5.cpp:20
↓ 5 callersFunctionremoveDuplicate1
Solutions/Chapter 1 Arrays and Strings/1.3.cpp:13
↓ 5 callersFunctionremoveDuplicate2
Solutions/Chapter 1 Arrays and Strings/1.3.cpp:31
↓ 5 callersFunctionremoveDuplicate5
Solutions/Chapter 1 Arrays and Strings/1.3.cpp:85
↓ 4 callersMethodfull
Solutions/Chapter 3 Stacks and Queues/3.3.cpp:41
↓ 4 callersMethodheight
* @brief Returns the height of the rectangle. * @note Complexity: O(1) in both time and space. */
Solutions/Chapter 20 Hard/20.13.cpp:210
↓ 4 callersFunctionmagnitude
* @brief Computes |a| using only additions. * @note Complexity: O(|a|) in time, O(1) in space. */
Solutions/Chapter 10 Mathematical/10.4.cpp:44
↓ 4 callersFunctionmax
Solutions/Chapter 20 Hard/20.11.cpp:18
↓ 4 callersMethodpop
Solutions/Chapter 3 Stacks and Queues/3.3.cpp:32
↓ 4 callersFunctionprint_binary
Solutions/Chapter 5 Bit Manipulation/5.6.cpp:10
↓ 4 callersFunctionswap
Solutions/Chapter 1 Arrays and Strings/1.2.cpp:9
↓ 4 callersMethodwidth
* @brief Returns the width of the rectangle. * @note Complexity: O(1) in both time and space. */
Solutions/Chapter 20 Hard/20.13.cpp:201
↓ 3 callersFunctionfact
Solutions/Chapter 8 Recursion/8.2.cpp:27
↓ 3 callersFunctionfather
Solutions/Chapter 4 Trees and Graphs/4.6.cpp:54
↓ 3 callersMethodfind
* @brief Returns true if a given word is in the dictionary, false * otherwise. * @note Complexity: O(n) in time, O(1) in space, whe
Solutions/Chapter 20 Hard/20.13.cpp:86
↓ 3 callersMethodmin
Solutions/Chapter 3 Stacks and Queues/3.2.cpp:39
↓ 3 callersMethodpopAt
Solutions/Chapter 3 Stacks and Queues/3.3.cpp:102
↓ 3 callersFunctionprint
Solutions/Chapter 2 Linked Lists/2.4.cpp:86
↓ 3 callersFunctionprint_binary
Solutions/Chapter 5 Bit Manipulation/5.1.cpp:11
↓ 3 callersMethodpush
Solutions/Chapter 3 Stacks and Queues/3.3.cpp:29
↓ 3 callersMethodtop
Solutions/Chapter 3 Stacks and Queues/3.1.cpp:26
↓ 2 callersFunctionCheckDiagonal
Solutions/Chapter 19 Moderate/19.2.cpp:41
↓ 2 callersFunctionCheckRowColumn
Solutions/Chapter 19 Moderate/19.2.cpp:13
↓ 2 callersFunctionbuild_all_lines
* @brief Returns a vector with all lines which connect each pair of points * on an array with n distinct points. * @note Complexity: O(n²)
Solutions/Chapter 10 Mathematical/10.6.cpp:19
↓ 2 callersFunctioncreate_minimal_tree
Solutions/Chapter 4 Trees and Graphs/4.7.cpp:24
↓ 2 callersFunctioninit
Solutions/Chapter 2 Linked Lists/2.4.cpp:19
↓ 2 callersFunctioninsert
Solutions/Chapter 4 Trees and Graphs/BST.cpp:21
↓ 2 callersFunctionisUnique1
Solutions/Chapter 1 Arrays and Strings/1.1.cpp:9
↓ 2 callersFunctionisUnique2
Solutions/Chapter 1 Arrays and Strings/1.1.cpp:23
↓ 2 callersFunctionmaximum
Solutions/Chapter 4 Trees and Graphs/BST.cpp:58
↓ 2 callersFunctionminimum
Solutions/Chapter 4 Trees and Graphs/BST.cpp:51
↓ 2 callersFunctionmul
Solutions/Chapter 8 Recursion/8.1.cpp:28
↓ 2 callersFunctionprint
Solutions/Chapter 2 Linked Lists/2.3.cpp:50
↓ 2 callersFunctionprint_subsets
Solutions/Chapter 8 Recursion/8.3.cpp:55
↓ 2 callersFunctionreplace1
Solutions/Chapter 1 Arrays and Strings/1.5.cpp:9
↓ 2 callersFunctionsearch
Solutions/Chapter 4 Trees and Graphs/4.6.cpp:80
↓ 2 callersMethodsubcolumn
* @brief Returns the topmost contiguous sequence of defined characters * at the j-th column. * @note Complexity: O(height) in both
Solutions/Chapter 20 Hard/20.13.cpp:183
↓ 2 callersMethodsubrow
* @brief Returns the leftmost contiguous sequence of defined characters * at the i-th row. * @note Complexity: O(width) in both tim
Solutions/Chapter 20 Hard/20.13.cpp:164
↓ 2 callersFunctionswap
Solutions/Chapter 9 Sorting and Searching/9.1.1.cpp:8
↓ 2 callersFunctionswap
Solutions/Chapter 1 Arrays and Strings/1.6.cpp:15
↓ 2 callersMethodtop
Solutions/Chapter 3 Stacks and Queues/3.3.cpp:35
↓ 2 callersMethodvalid_next_chars
* @brief Given a word prefix, returns a bitmask indicating what are the * possible next characters if the prefix is assumed to be part
Solutions/Chapter 20 Hard/20.13.cpp:67
↓ 1 callersFunctionAdd1
Solutions/Chapter 20 Hard/20.1.cpp:9
↓ 1 callersFunctionAdd2
Solutions/Chapter 20 Hard/20.1.cpp:15
↓ 1 callersFunctionAdd3
Solutions/Chapter 20 Hard/20.1.cpp:23
↓ 1 callersFunctionCount2
Solutions/Chapter 20 Hard/20.4.cpp:8
↓ 1 callersFunctionCount2s
Solutions/Chapter 20 Hard/20.4.cpp:30
↓ 1 callersFunctionCount2s1
Solutions/Chapter 20 Hard/20.4.cpp:20
↓ 1 callersFunctionCountis
Solutions/Chapter 20 Hard/20.4.cpp:60
↓ 1 callersFunctionEstimate
Solutions/Chapter 19 Moderate/19.5.cpp:24
↓ 1 callersFunctionEstimate1
Solutions/Chapter 19 Moderate/19.5.cpp:50
↓ 1 callersFunctionFindSubSquare
Solutions/Chapter 20 Hard/20.11.cpp:39
↓ 1 callersFunctionGetMaxSum
Solutions/Chapter 19 Moderate/19.7.cpp:14
↓ 1 callersMethodGetValue
Solutions/Chapter 20 Hard/20.9.cpp:54
↓ 1 callersFunctionHasWon
Solutions/Chapter 19 Moderate/19.2.cpp:68
↓ 1 callersMethodInsert
Solutions/Chapter 20 Hard/20.9.cpp:24
↓ 1 callersFunctionIsSquare
Solutions/Chapter 20 Hard/20.11.cpp:23
↓ 1 callersFunctionMakeOfWords
Solutions/Chapter 20 Hard/20.7.cpp:16
↓ 1 callersFunctionMax1
Solutions/Chapter 19 Moderate/19.4.cpp:8
↓ 1 callersFunctionMax2
Solutions/Chapter 19 Moderate/19.4.cpp:16
↓ 1 callersFunctionMaxSum
Solutions/Chapter 20 Hard/20.12.cpp:22
↓ 1 callersMethodMethodA
Solutions/Chapter 13 CPP/13.6.cpp:10
↓ 1 callersFunctionMin
Solutions/Chapter 19 Moderate/19.5.cpp:45
↓ 1 callersFunctionNumZero1
Solutions/Chapter 19 Moderate/19.3.cpp:19
↓ 1 callersFunctionNumZeros
Solutions/Chapter 19 Moderate/19.3.cpp:8
↓ 1 callersFunctionPickMRandomly
Solutions/Chapter 20 Hard/20.3.cpp:16
↓ 1 callersFunctionPreCompute
Solutions/Chapter 20 Hard/20.12.cpp:13
↓ 1 callersFunctionPrintLongestWord
Solutions/Chapter 20 Hard/20.7.cpp:34
↓ 1 callersFunctionPrintPairSum
Solutions/Chapter 19 Moderate/19.11.cpp:9
↓ 1 callersFunctionQsort
Solutions/Chapter 3 Stacks and Queues/3.6.cpp:14
↓ 1 callersFunctionRandomShuffle
Solutions/Chapter 20 Hard/20.2.cpp:18
↓ 1 callersFunctionShortestDist
Solutions/Chapter 20 Hard/20.5.cpp:13
↓ 1 callersFunctionSwap
Solutions/Chapter 20 Hard/20.2.cpp:12
↓ 1 callersFunctionSwap
Solutions/Chapter 20 Hard/20.3.cpp:10
↓ 1 callersFunctionaddlink
Solutions/Chapter 2 Linked Lists/2.4.cpp:37
↓ 1 callersFunctionbuild_largest_word_rectangle
* @brief Builds the largest rectangle of characters such that each of its rows * and columns forms a word in a given dictionary. * @note Co
Solutions/Chapter 20 Hard/20.13.cpp:325
↓ 1 callersFunctionbuild_rectangle
* @brief Recursive step on the backtracking implementation; at each call, all * cells rect(0:i, 0:j) except for rect(i,j) are assumed to be a
Solutions/Chapter 20 Hard/20.13.cpp:258
↓ 1 callersMethodconstruct
Solutions/Chapter 20 Hard/ac_automation.cpp:51
↓ 1 callersFunctioncontain_tree
Solutions/Chapter 4 Trees and Graphs/4.7.cpp:52
↓ 1 callersFunctionconvert_num
Solutions/Chapter 5 Bit Manipulation/5.5.cpp:19
↓ 1 callersFunctioncount_one
Solutions/Chapter 5 Bit Manipulation/5.5.cpp:10
↓ 1 callersFunctioncount_words
* @brief Returns a map containing the number of occurrences of each unique * word read from an input stream. * @note Complexity: O(n*m*log(
Solutions/Chapter 19 Moderate/19.8.cpp:16
↓ 1 callersFunctioncreateMinimalTree
Solutions/Chapter 4 Trees and Graphs/4.4.cpp:27
next →1–100 of 382, ranked by callers