If you are a teenager (below 20 in age and mind), and you are in tech.....
Quote this post with an introduction of yourself...
Hi, I'm [name]
I'm a [age] y/o [what you do]
and attach a good picture of yourself 😊
Day 34/50: Reverse Bits 🔄
Used bit manipulation to iterate through all 32 bits, shifting and building the reversed integer bit by bit to achieve O(1) time and space complexity!
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 33/50: Counting Bits
Used Dynamic Programming with bit manipulation to compute the number of 1 bits for each number from 0 to n in a single pass, achieving O(n) time complexity!
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 32/50: Generate Parentheses
Used backtracking to build valid combinations by tracking open and close parenthesis counts, ensuring validity on-the-fly and achieving O(4^n/n^1/2) time complexity
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#ML#BuildInPublic
Day 31/50: Balanced Binary Tree
Used a bottom-up depth-first search (DFS) approach to compute tree heights and check balance factors simultaneously, achieving O(n) time and O(h) space complexity!
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#ML#BuildInPublic
Day 30/50: Maximum Subarray 📈
Used Kadane's Algorithm with dynamic programming to find the contiguous subarray with the largest sum, achieving O(n) time and O(1) space complexity!
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 29/50: Subsets 🧩
Used an iterative cascading approach to build all possible subsets by appending each new number to existing subsets, achieving O(2^n•n) time complexity
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 28/50: Permutations
Used backtracking to systematically explore and generate all unique permutations of an array of numbers, achieving O(n•n!) time and O(n) space complexity!
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 27/50: Last Stone Weight
Simulated the stone-smashing game by repeatedly sorting the array to extract the two heaviest stones, achieving O(n^2logn) time and O(n) space complexity!
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 26/50: Remove Nth Node From End of List
Used a two-pointer approach with a dummy node and an n-step gap offset to remove the target node in a single pass. In O(N) time complexity.
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 25/50: Find the Duplicate Number
Used Floyd’s Tortoise and Hare
algorithm to find the duplicate integer without modifying the array, in O(n) time and O(1) space complexity!
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 24/50: Linked List Cycle
Used Floyd’s Cycle-Finding Algorithm (Fast & Slow Pointers) to detect a loop in a linked list, running in O(n) time complexity and O(1) space complexity!
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 23/50: Min Cost Climbing Stairs
Used Dynamic Programming with bottom-up tabulation, optimizing space by tracking only the last two step costs to find the minimum cost to reach the top in O(n) time complexity
Sticking to the grind! 💻🔥
#LeetCode#ML#buildinginpublic
Day 22/50: Number of 1 Bits 🔢
Used Brian Kernighan’s algorithm to clear the lowest set bit in each iteration, counting set bits in O(k) time complexity and O(1) space complexity
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#buildinginpublic
Day 21/50: Reverse Integer 🔄
Reversed the digits of a 32-bit signed integer using modulo arithmetic and bit to handle overflow checks in O(log_{10}(x)) time complexity.
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#buildinginpublic
Day 20/50: Letter Combinations of a Phone Number
Used backtracking to map digit keys to their corresponding letters, generating all possible letter combinations in O(4^n•n) time.
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#BuildInPublic
Day 19/50: Valid Palindrome
Used the two-pointer technique to skip non-alphanumeric characters and verify if a string reads the same forwards and backwards in O(n) time complexity.
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#buildinginpublic
Day 18/50: Missing Number
Used the Gauss sum formula to compute the expected total from 0 to n and subtracted the actual sum to find the missing integer in O(n) time complexity.
Sticking to the grind! 💻🔥
#LeetCode#NeetCode#DataScience#MachineLearning#buildinginpublic