├── Array-algorithms ├── Counting-sort.py ├── K-th-element.py ├── Kadane-algorithm.py ├── Longest-common-subequence.py ├── Longest-common-substring.py ├── Longest-increasing-subsequence.py ├── Maximum-xor-of-two-numbers.py └── Z-algorithm.py ├── Data-structures ├── Disjoint-set.py ├── Heap-custom-comparator.py ├── Segment-tree-lazy.py ├── Segment-tree.py ├── Treap.py ├── Trie-binary.py └── Trie-string.py ├── Graph-algorithms └── Dijkstra.py ├── Mathematics ├── Continued-fractions.py ├── Number-theory │ ├── Bell-numbers.py │ ├── Bernoulli-numbers.py │ ├── Binomial-numbers.py │ ├── Catalan-numbers.py │ ├── Chinese-remainder-theorem.py │ ├── Euclidean-algorithms.py │ ├── Euler-totient-function.py │ ├── Legendre-symbol.py │ ├── Modular-square-root.py │ ├── Sieving-methods │ │ ├── Divisor-functions.py │ │ ├── Euler-totient-function.py │ │ ├── Mobius-function.py │ │ ├── Prime-counting-function.py │ │ ├── Sieve-of-Eratosthenes.py │ │ └── Totient-summatory-function.py │ ├── Stirling-numbers-first-kind.py │ └── Stirling-numbers-second-kind.py └── Precise-square-root.py ├── Miscellaneous ├── Binary-search.py ├── Iterated-sequence-cycle.py └── Ternary-search.py ├── README.md └── Recursion-limits.py /Array-algorithms/Counting-sort.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Array-algorithms/Counting-sort.py -------------------------------------------------------------------------------- /Array-algorithms/K-th-element.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Array-algorithms/K-th-element.py -------------------------------------------------------------------------------- /Array-algorithms/Kadane-algorithm.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Array-algorithms/Kadane-algorithm.py -------------------------------------------------------------------------------- /Array-algorithms/Longest-common-subequence.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Array-algorithms/Longest-common-subequence.py -------------------------------------------------------------------------------- /Array-algorithms/Longest-common-substring.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Array-algorithms/Longest-common-substring.py -------------------------------------------------------------------------------- /Array-algorithms/Longest-increasing-subsequence.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Array-algorithms/Longest-increasing-subsequence.py -------------------------------------------------------------------------------- /Array-algorithms/Maximum-xor-of-two-numbers.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Array-algorithms/Maximum-xor-of-two-numbers.py -------------------------------------------------------------------------------- /Array-algorithms/Z-algorithm.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Array-algorithms/Z-algorithm.py -------------------------------------------------------------------------------- /Data-structures/Disjoint-set.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Data-structures/Disjoint-set.py -------------------------------------------------------------------------------- /Data-structures/Heap-custom-comparator.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Data-structures/Heap-custom-comparator.py -------------------------------------------------------------------------------- /Data-structures/Segment-tree-lazy.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Data-structures/Segment-tree-lazy.py -------------------------------------------------------------------------------- /Data-structures/Segment-tree.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Data-structures/Segment-tree.py -------------------------------------------------------------------------------- /Data-structures/Treap.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Data-structures/Treap.py -------------------------------------------------------------------------------- /Data-structures/Trie-binary.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Data-structures/Trie-binary.py -------------------------------------------------------------------------------- /Data-structures/Trie-string.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Data-structures/Trie-string.py -------------------------------------------------------------------------------- /Graph-algorithms/Dijkstra.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Graph-algorithms/Dijkstra.py -------------------------------------------------------------------------------- /Mathematics/Continued-fractions.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Continued-fractions.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Bell-numbers.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Bell-numbers.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Bernoulli-numbers.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Bernoulli-numbers.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Binomial-numbers.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Binomial-numbers.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Catalan-numbers.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Catalan-numbers.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Chinese-remainder-theorem.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Chinese-remainder-theorem.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Euclidean-algorithms.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Euclidean-algorithms.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Euler-totient-function.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Euler-totient-function.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Legendre-symbol.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Legendre-symbol.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Modular-square-root.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Modular-square-root.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Sieving-methods/Divisor-functions.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Sieving-methods/Divisor-functions.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Sieving-methods/Euler-totient-function.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Sieving-methods/Euler-totient-function.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Sieving-methods/Mobius-function.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Sieving-methods/Mobius-function.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Sieving-methods/Prime-counting-function.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Sieving-methods/Prime-counting-function.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Sieving-methods/Sieve-of-Eratosthenes.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Sieving-methods/Sieve-of-Eratosthenes.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Sieving-methods/Totient-summatory-function.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Sieving-methods/Totient-summatory-function.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Stirling-numbers-first-kind.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Stirling-numbers-first-kind.py -------------------------------------------------------------------------------- /Mathematics/Number-theory/Stirling-numbers-second-kind.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Number-theory/Stirling-numbers-second-kind.py -------------------------------------------------------------------------------- /Mathematics/Precise-square-root.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Mathematics/Precise-square-root.py -------------------------------------------------------------------------------- /Miscellaneous/Binary-search.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Miscellaneous/Binary-search.py -------------------------------------------------------------------------------- /Miscellaneous/Iterated-sequence-cycle.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Miscellaneous/Iterated-sequence-cycle.py -------------------------------------------------------------------------------- /Miscellaneous/Ternary-search.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Miscellaneous/Ternary-search.py -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Competitive programming in Python 3 2 | -------------------------------------------------------------------------------- /Recursion-limits.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/markopuza/Competitive-programming-in-Python/HEAD/Recursion-limits.py --------------------------------------------------------------------------------