Day: 25/365 Problem: Find Smallest Letter Greater Than Target Easy #POTD #365DaysOfCode #DSA #Java #ProblemSolving #Consistency 🥷 Key takeaways/Learnings from this problem: 1. This one’s a classic reminder that binary search isn’t just for numbers, it works beautifully on sorted characters too.
Binary Search for Characters in Java
More Relevant Posts
-
Day 8 – Maximum Product of Two Elements Solved a problem that requires finding the maximum product from two array elements. Key Learnings: Tracking the largest and second-largest values in one pass Avoiding extra operations like sorting when not required Writing clear conditional logic #Java #Arrays #ProblemSolving #DSA
To view or add a comment, sign in
-
-
#day314 of #1001daysofcode problem statement (0693): Binary Number with Alternating Bits Used XOR with right shift to transform alternating bits into a sequence of 1s, then applied the (x & (x + 1)) == 0 pattern(tocheck all bits are set bits or not). Sometimes bit tricks make problems beautifully simple. #1001DaysOfCode #DSA #Java #LeetCode #ProblemSolving Shivam Mahajan #leetcode
To view or add a comment, sign in
-
-
#day316 & #day317 of #1001daysofcode problem statement (0762): Prime Number of Set Bits in Binary Representation problem statement (0868): Binary Gap Tracked positions of consecutive 1s using bit manipulation and computed the maximum distance between them. #1001DaysOfCode #DSA #Java #LeetCode #ProblemSolving Shivam Mahajan #leetcode
To view or add a comment, sign in
-
-
Day: 40/365 📌 LeetCode POTD: Add Binary Easy Key takeaways/Learnings from this problem: 1. This one’s a reminder that binary addition is just normal addition with a carry you manage manually, nothing fancy. 2. Big takeaway: when strings represent numbers, think digit-by-digit from the end — clean logic > converting to integers. #POTD #365DaysOfCode #DSA #Java #ProblemSolving #LearningInPublic #Consistency 🥷
To view or add a comment, sign in
-
-
🚀Java practice - Day 72 Completed! 👍 Problem: Check if All Characters Have Equal Number of Occurrences Language: Java Today’s problem focused on validating whether all characters in a string appear the same number of times. A simple concept, but it required careful frequency tracking and comparison.✨ #Day72 #Java #LeetCode #Strings #HashMap #ProblemSolving #DailyCoding #Consistency #100DaysOfCode
To view or add a comment, sign in
-
-
🚀 Day 6 of #100DaysOfDSA (Java) Today I worked on Pattern Problems ⭐ Focused on: Nested loops Row & column logic Understanding how output structure maps to loop structure At first, patterns feel confusing. But once you understand how rows and columns interact, everything becomes structured. Big takeaway today 👇 Patterns improve logical thinking and control over loops — which is the foundation for solving complex problems later. Small practice. Strong foundation. Day 6 ✅ Consistency is building discipline. #DSA #Java #CodingJourney #100DaysOfCode #ProblemSolving #FutureDeveloper #LearningInPublic
To view or add a comment, sign in
-
-
🚀 Day 5 of #100DaysOfDSA (Java) Today was all about Loops & Control Flow 🔁 Covered: while loop do-while loop break and continue Practice problems using loop-based logic One thing I realized today 👇 Loops are simple in syntax but powerful in logic. They teach you how to think in patterns, repetitions, and edge cases. Understanding when to use: while (condition first) do-while (execute at least once) break (exit early) continue (skip iteration) …makes your code cleaner and more controlled. Small concepts. Big foundation. Consistency check: ✅ Day 5 done. 95 days to go. #DSA #Java #CodingJourney #100DaysOfCode #FutureFullStackDeveloper #LearningInPublic #DeveloperMindset
To view or add a comment, sign in
-
-
#100DaysOfCode 👉 LeetCode #392 – Is Subsequence 📘 Problem Statement : Given two strings s and t, return true if s is a subsequence of t, otherwise return false. A string s is considered a subsequence of t if it can be formed by deleting some characters from t without changing the order of the remaining characters. 🔍 Example s = "ace", t = "abcde" → ✅ True s = "aec", t = "abcde" → ❌ False 💡 Approach (Two Pointer Technique) Use two pointers: One pointer for string s One pointer for string t If characters match → move both pointers If not → move pointer of t If all characters of s are matched → s is a subsequence ⏱️ Time & Space Complexity Time Complexity: O(n) Space Complexity: O(1) Day 7 #CodingPractice #TCSNQT #DSA #Java #ProblemSolving #LearnInPublic #Subsequence #PlacementPreparation
To view or add a comment, sign in
-
-
Day: 44/365 📌 LeetCode POTD: Count Binary Substrings Easy Key takeaways/Learnings from this problem: 1. The real trick is noticing you don’t need to check every substring — just track lengths of consecutive 0s and 1s. 2. Big takeaway: many string problems become simple once you focus on grouping patterns instead of brute force counting. #POTD #365DaysOfCode #DSA #Java #ProblemSolving #LearningInPublic #Consistency 🥷
To view or add a comment, sign in
-
-
Day 109 🚀 | Restore String (LeetCode) Rebuild the string using index mapping 🔁 👉 Place each character at its correct position ⏱ O(n) | 📦 O(n) Consistency > everything 💪 #Day109 #LeetCode #DSA #Java #GeekStreak #CodingJourney
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