This is a collection of my HackerRank, Codeforces, Geeks for Geeks, and LeetCode problem solutions in C++, Java, and Python 3. These are not meant to be competition style implementations but clean and easily understandable algorithms for learning purposes.
- Algorithms
- Artificial Intelligence
- Data Structures
- Mathematics
- 229D Towers
- 276C Little Girl and Maximum Sum
- 342E Xenia and Tree
- 547B Mike and Feet
- 637D Running with Obstacles
- 749D Leaving Auction
- 750D New Year and Fireworks
- 753B Interactive Bulls and Cows (Easy)
- 753C Interactive Bulls and Cows (Hard)
- 754D Fedor and Coupons
- 758D Ability To Convert
- 758E Broken Tree
- 758F Geometric Progression
- 780D Innokenty and a Football League
- 780E Underground Lab
- 792D Paths in a Complete Binary Tree
- 796D Police Stations
- 796E Exam Cheating
- 815C Karen and Supermarket
- 818D Multicolored Cars
- 819B Mister B and PR Shifts
- 819E Mister B and Flight to the Moon
- 827C DNA Evolution
- 830B Cards Sorting
- 833B The Bakery
- 835E The Penguin's Game
- Algorithms
- 4Sum
- Basic Calculator
- Preorder and Inorder Traversal
- Postorder and Inorder Traversal
- Binary Tree Maximum Path Sum
- Binary Tree Zigzag Level Order Traversal
- Burst Balloons
- Closest Palindrome
- Container With Most Water
- Contains Duplicate III
- Data Stream as Disjoint Intervals
- Difference Ways to Add Parenthesis
- Distinct Subsequences
- Dungeon Game
- Edit Distance
- Encode String with Shortest Length
- Flatten Binary Tree to Linked List
- Game of Life
- Gas Station
- Interleaving String
- Is Balanced
- K Pairs with Smallest Sums
- Kth Largest Element
- Kth Smallest Element in Sorted Matrix
- Largest Rectangle in Histogram
- LCA of a Binary Tree
- Lexicographical Numbers
- LFU Cache
- Linked List Cycle II
- Longest Valid Parenthesis
- Majority Element II
- Max Points on a Line
- Maximum Gap
- Median of Two Sorted Arrays
- Mini Parser
- Minimum Height Tree
- Minimum Window Substring
- N-Queens II
- Non Overlapping Intervals
- Palindrome Linked List
- Palindrome Pairs
- Permutation Sequence
- Permutations II
- Range Sum Query - Mutable
- Recover Binary Tree
- Rectangle Area
- Regular Expression Matching
- Remove Duplicates from Sorted Array II
- Remove K Digits
- Reverse Nodes in k-Group
- Reverse Words in a String
- Rotate Image
- Set Matrix Zeroes
- Skyline
- Sliding Window Maximum
- Shortest Palindrome
- Sorted Array to BST
- Spiral Matrix
- Sqrt(x)
- Stock Profit III
- Stock Profit IV
- Subsets II
- Substring with Concatenation of All Words
- Sudoku Solver
- Unique Substrings in Wraparound String
- Validate BST
- Wiggle Subsequence
- Wildcard Matching
- Word Break