leetcode/references

references

dz / leetcode / references

Subgraphs

Node Tree

Nodes

optimization_problem
content Optimization Problem (Computer Science): the problem of finding the best solution from all feasible solutions.
children candidate_solution (the "best solution" is a candidate solution)
parents leetcode/problems/322_coin_change
hyperlink https://en.wikipedia.org/wiki/Optimization_problem
flashcard (front) What is an optimization problem?
flashcard (back) the problem of finding the best solution from all feasible solutions.

candidate_solution
content Candidate solution: member of the set of possible solutions in the feasible region of given problems.
parents optimization_problem
flashcard (front) What is a candidate solution?
flashcard (back) A candidate solution is a solution in the feasible region of given problems.

optimal_substructure
content Optimal Substructure: in computer sience, a problem is said to have optimal substructure if an optimal solution can be constructed from optimal solutions of its subproblems.
children recurrence_relation (used to represent optimal substructure)
parents leetcode/paradigms/dynamic_programming, leetcode/problems/322_coin_change
hyperlink https://en.wikipedia.org/wiki/Optimal_substructure
flashcard (front) What is optimal substructure?
flashcard (back) Optimal substructure is a property of a problem where an optimal solution can be constructed from optimal solutions of its subproblems.

recurrence_relation
content Recurrence Relation: In mathematics, a recurrence relation is an equation according to which the n nth term of a sequence of numbers is equal to some combination of the previous terms.
parents optimal_substructure, leetcode/problems/322_coin_change
hyperlink https://en.wikipedia.org/wiki/Recurrence_relation

bottom_up_top_down
content Bottom-up and Top-down design: are both strategies of information processing and ordering knowledge, used in a variety of fields including software, humanistic and scientific theories (see systemics), and management and organization. In practice they can be seen as a style of thinking, teaching, or leadership.
parents leetcode/paradigms/dynamic_programming, leetcode/problems/322_coin_change
hyperlink https://en.wikipedia.org/wiki/Bottom%E2%80%93up_and_top%E2%80%93down_design

dynamic_programming
content Dynamic Programming: A mathematicl optimization method and an algorithmic paradigm.
parents leetcode/paradigms/dynamic_programming
hyperlink https://en.wikipedia.org/wiki/Dynamic_programming

algorithmic_paradigm
content Algorithmic Paradigm: An algorithmic paradigm is a generic model or framework which underlies the design of a class of algorithms.
parents leetcode/paradigms/algorithmic_paradigm
hyperlink https://en.wikipedia.org/wiki/Algorithmic_paradigm

prefix_sum
content Prefix Sum
parents leetcode/problems/643_maximum_average_subarray, leetcode/problems/238_product_of_array_except_self
hyperlink https://en.wikipedia.org/wiki/Prefix_sum

binary_search_tree
content Binary Search Tree
parents leetcode/data_structures/binary_search_tree
hyperlink https://en.wikipedia.org/wiki/Binary_search_tree

tree_traversal
content tree traversal
hyperlink https://en.wikipedia.org/wiki/Tree_traversal

depth_first_search
content Depth-First-Search (DFS)
parents leetcode/paradigms/depth_first_search
hyperlink https://en.wikipedia.org/wiki/Depth-first_search

disjoint_data_set
content Disjoint Data Set: a data structure that stores a collection of disjoint (non-overlapping) sets.
parents leetcode/problems/200_number_of_islands
hyperlink https://en.wikipedia.org/wiki/Disjoint-set_data_structure

breadth_first_search
content Bread-first search (BFS)
parents leetcode/paradigms/breadth_first_search
hyperlink https://en.wikipedia.org/wiki/Breadth-first_search

binary_search
content Binary Search: algorithm that finds the position of a target value in a sorted array.
children sorted_array (sorted array is the data structure used in binary search)
parents leetcode/paradigms/binary_search
hyperlink https://en.wikipedia.org/wiki/Binary_search

binary_search_java
content Binary Search code snippet in Java, with with code comments
parents leetcode/paradigms/binary_search
remarks Recommended by EV
hyperlink https://algs4.cs.princeton.edu/11model/BinarySearch.java.html

sorted_array
content Sorted Array: an array data structure where each element is sorted in numerical, alphabetical, or some other order.
parents binary_search
hyperlink https://en.wikipedia.org/wiki/Sorted_array

opionated_guide_binary_search
content An opinionated guide to binary search
parents leetcode/paradigms/binary_search
hyperlink https://leetcode.com/discuss/study-guide/2371234/An-opinionated-guide-to-binary-search-

backtracking
content Backtracking
parents leetcode/paradigms/backtracking
hyperlink https://en.wikipedia.org/wiki/Backtracking

knapsack_problem
content Knapsack problem: given a set of items, each with a weight and a value, determine which items to include in the collection so that the total weight is less than or equal to a given limit and the total value is as large as possible.
parents combinatorial_optimization, leetcode/problems/39_combination_sum
hyperlink https://en.wikipedia.org/wiki/Knapsack_problem
flashcard (front) What is the knapsack problem?
flashcard (back) The knapsack problem can be described as: given a set of items, each with a weight and a value, determine which items to include in the collection so that the total weight is less than or equal to a given limit and the total value is as large as possible.

combinatorial_optimization
content Combinatorial optimization is a subfield of mathematical optimization that consists of finding an optimal object from a finite set of objects,[1] where the set of feasible solutions is discrete or can be reduced to a discrete set.
children knapsack_problem (knapsack problem is a problem in combinatorial optimization)
hyperlink https://en.wikipedia.org/wiki/Combinatorial_optimization

binary_search_leetcode
content Binary Search Leetcode explore card
parents leetcode/paradigms/binary_search
hyperlink https://leetcode.com/explore/learn/card/binary-search/

hash_table
content A hash table is a data structure that implements an associative array, also called a dictionary or map.
parents leetcode/data_structures/hash_table, associative_array
hyperlink https://en.wikipedia.org/wiki/Hash_table

associative_array
content associative array: an abstract data type that stores a collection of key-value pairs, such that each possible key appears at most once in the collection.
children hash_table (a hash table implements an associative array)
hyperlink https://en.wikipedia.org/wiki/Associative_array

abstract_data_type
content abstract data type: mathematical model for data types, defined by its behavior (semantics) from the point of view of a user of the data, specifically in terms of possible values, possible operations on the data of this type, and the behavior of these operations.
children stack
hyperlink https://en.wikipedia.org/wiki/Abstract_data_type

stack
content Stack (abstract data type)
parents abstract_data_type
hyperlink https://en.wikipedia.org/wiki/Stack_(abstract_data_type)

linked_list
content linked list
parents leetcode/data_structures/linked_list
hyperlink https://en.wikipedia.org/wiki/Linked_list

maximum_subarray_problem
content Maximum Subarray problem
children kadanes (used to solve maximum subarray problem)
parents leetcode/problems/121_best_time_to_sell_and_buy_stock
hyperlink https://en.wikipedia.org/wiki/Maximum_subarray_problem

kadanes
content Kadane's algorithm
parents leetcode/problems/121_best_time_to_sell_and_buy_stock, maximum_subarray_problem
hyperlink https://en.wikipedia.org/wiki/Maximum_subarray_problem#Kadane's_algorithm

greedy_algorithm
content Greedy Algorithm
parents leetcode/paradigms/greedy
hyperlink https://en.wikipedia.org/wiki/Greedy_algorithm

two_pointer_technique
content Two-Pointer Technique (leetcode)
hyperlink https://leetcode.com/articles/two-pointer-technique/

lowest_common_ancestor
content Lowest Common Ancestor: the LCA of two nodes v and w in a tree or DAG is the lowest node that has both v and w as descendants, where we define each node to be a descendant of itself
parents leetcode/problems/235_lowest_common_ancestor_BST
hyperlink https://en.wikipedia.org/wiki/Lowest_common_ancestor

binary_tree
content Binary Tree: tree data structure in which a node has at most two children: a left child and a right child.
parents leetcode/data_structures/binary_tree
hyperlink https://en.wikipedia.org/wiki/Binary_tree

floyds_algorithm
content Floyd's Cycle Finding Algorithm
children leetcode/problems/876_middle_of_linked_list (the fast/slow pointer trick made me think of floyd's algorithm)
parents leetcode/problems/287_find_the_duplicate_number, leetcode/data_structures/linked_list, leetcode/problems/141_linked_list_cycle
hyperlink https://en.wikipedia.org/wiki/Cycle_detection#Floyd's_tortoise_and_hare
flashcard (front) Describe Floyd's algorithm
flashcard (back) Floyd's algorithm can be used for cycle detection in linked lists (think tortois and hare). You a slow pointer a fast pointer. If there's a cycle, the fast pointer will eventually lap the fast pointer.

queues
content Queue (Abstract Data Type)
parents leetcode/data_structures/queue
hyperlink https://en.wikipedia.org/wiki/Queue_(abstract_data_type)

boyer_moore_majority_vote_algorithm
content Boyer-Moore majority vote algorithm
parents leetcode/problems/169_majority_element
hyperlink https://en.wikipedia.org/wiki/Boyer%E2%80%93Moore_majority_vote_algorithm

tail_call
content tail call: subroutine performed as the final action of a procedure
parents leetcode/problems/104_max_depth_binary_tree
hyperlink https://en.wikipedia.org/wiki/Tail_call