✨Day 67 LeetCode: Letter Combinations of a Phone Number (17) Approach: Used backtracking to generate all possible letter combinations mapped from digits, following the classic phone keypad pattern. ✨ Learned how recursion and backtracking can explore all possible paths efficiently — a great exercise in mapping and combinatorial logic! 📈 Improved understanding of recursion, string building, and backtracking patterns in C++. #LeetCode #100DaysOfCode #DSA #Backtracking #Strings #ProblemSolving #CodingJourney #CodeEveryday
"Day 67: LeetCode Challenge with Backtracking in C++"
More Relevant Posts
-
🌻Day 56 LeetCode: Number of Ways to Split Array (2270) Approach: Calculated prefix sums to efficiently determine valid split points where the left sum is greater than or equal to the right sum. ✨ Learned how prefix sums simplify cumulative comparison problems and help avoid repeated summations — boosting both logic and efficiency! 📈 Improved understanding of prefix arrays, cumulative sums, and linear-time array traversal in C++. #LeetCode #100DaysOfCode #DSA #Arrays #PrefixSum #ProblemSolving #CodingJourney #CodeEveryday
To view or add a comment, sign in
-
-
🌿Day 52 LeetCode: Valid Sudoku (36) Approach: Used hash sets to track numbers appearing in each row, column, and 3×3 sub-box while validating the board. ✨ Learned how to handle 2D grids efficiently and apply set-based validation for constraints checking! 📈 Strengthened logical reasoning and improved understanding of hash sets and matrix traversal in C++. #LeetCode #100DaysOfCode #DSA #HashSet #Matrix #ProblemSolving #CodingJourney #LogicBuilding
To view or add a comment, sign in
-
-
🌿Day 73 LeetCode: Next Greater Element I (496) Approach: Used a stack to find the next greater element for each number in nums2 and stored results in a hash map for quick lookup in nums1. ✨ Learned how to use monotonic stacks for next-greater problems — a smart way to reduce time complexity and strengthen logic! 📈 Improved understanding of stacks, hash maps, and element mapping techniques in C++. #LeetCode #100DaysOfCode #DSA #Stack #HashMap #Arrays #ProblemSolving #CodingJourney #CodeEveryday
To view or add a comment, sign in
-
-
🌟Day 59 LeetCode: Subsets (78) Approach: Used backtracking to generate all possible subsets of a given array by exploring inclusion and exclusion of each element. ✨ Learned how recursion and backtracking can systematically explore all combinations — a classic and insightful problem! 📈 Improved understanding of recursion tree logic, subset generation, and backtracking techniques in C++. #LeetCode #100DaysOfCode #DSA #Backtracking #Recursion #ProblemSolving #CodingJourney #CodeEveryday
To view or add a comment, sign in
-
-
💫Day 72 LeetCode: Linked List Cycle (141) Approach: Used an unordered_set to store visited nodes while traversing the list. If a node is already present in the set, a cycle exists. ✨ Learned how hashing helps in detecting cycles efficiently without modifying the linked list — a clean and intuitive solution! 📈 Improved understanding of hash-based detection, pointer traversal, and cycle identification in C++. #LeetCode #100DaysOfCode #DSA #LinkedList #Hashing #ProblemSolving #CodingJourney #CodeEveryday
To view or add a comment, sign in
-
-
🪷Day 69 LeetCode: Merge Two Sorted Lists (21) Approach: Merged two sorted linked lists by comparing nodes one by one and building a new sorted list using pointer manipulation. ✨ Learned how to handle linked list traversal and merging efficiently — a classic problem to strengthen pointer logic! 📈 Improved understanding of linked list operations, conditional traversal, and iterative merging in C++. #LeetCode #100DaysOfCode #DSA #LinkedList #Pointers #ProblemSolving #CodingJourney #CodeEveryday
To view or add a comment, sign in
-
-
🔢 “Today was all about turning strings into numbers — one recursive call at a time.” 🚀 Day 54/150 – DSA Challenge ✅ Problem solved: String to Integer (atoi) – LeetCode 8 (Recursion Approach) Converting a string to an integer sounds simple… until you start handling edge cases. Steps I followed: 1. Skip leading spaces. 2. Check for sign (+ / -). 3. Parse digits recursively. 4. Handle overflow by bounding between INT_MIN and INT_MAX. The recursion gave it a clean logical flow — digit by digit, call by call. ⏳ Time: O(n) 📦 Space: O(n) (recursion stack) 💡 “Recursion isn’t just looping — it’s trusting the next call to finish what you started.” 🔥 From text to integers, one call at a time. #Day54 #DSA #150DaysChallenge #LeetCode #StriverSheet #Recursion #ProblemSolving #CodingJourney #Atoi
To view or add a comment, sign in
-
-
Day 50 of #100DaysOfCode – Roman Numeral Converter in C 🏛️🔢 Today I built a classic Roman numeral converter using arrays and loops in C! 💻✨ The program takes an integer (1–3999) and maps it to its Roman numeral equivalent using a greedy algorithm. I loved how clean and logical the approach felt—matching values from largest to smallest and subtracting as we go. Also added input validation to keep it robust. Seeing "3999" turn into "MMMCMXCIX" was oddly satisfying 😄 📌 Concepts practiced: Arrays of integers and strings Looping with conditions Input validation Greedy logic for numeral mapping 🧠 Feeling more confident with string handling and formatting. Next up: maybe a Roman-to-Integer reverse converter? #Day50 #100DaysOfCode #CProgramming #CodeChallenge #LearnByDoing #CodingJourney #DevLog #CodeNewbie
To view or add a comment, sign in
-
Shared Libraries in C++: Spent the day diving deep into how shared libraries (.so files) actually work behind the scenes, from compilation and linking to setting up the LD_LIBRARY_PATH and running executables that depend on them. The following are some important points: 1. How to compile object files (.o) using -fPIC for position-independent code 2. Creating a shared library with g++ -shared 3. Linking the shared library with the main program 4. Using LD_LIBRARY_PATH to help the loader find .so files at runtime 5. Debugging common errors like “cannot open shared object file: No such file or directory” It was quite interesting to see how dynamic linking actually reduces redundancy and helps modularize large C++ projects efficiently. The following snapshot covers all the commands.
To view or add a comment, sign in
-
-
🔗 Day 63 of #100DaysOfCode 🔗 🔹 Problem: Valid Parentheses – LeetCode ✨ Approach: Implemented a stack-based validation to ensure every opening bracket has a matching closing one in correct order. Each character is checked systematically — pushing opens and popping closes — making it both clean and efficient! ⚡ 📊 Complexity Analysis: Time Complexity: O(n) — single traversal of the string Space Complexity: O(n) — stack usage for unmatched brackets ✅ Runtime: 2 ms (Beats 97.47%) ✅ Memory: 41.96 MB 🔑 Key Insight: Stacks are the unsung heroes of structured logic — from parentheses validation to syntax parsing, they keep the balance just right. 🧠 #LeetCode #100DaysOfCode #ProblemSolving #DSA #Stack #AlgorithmDesign #CodeJourney #ProgrammingChallenge #LogicBuilding #Efficiency #CodingDaily
To view or add a comment, sign in
-
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development