Code and approach to so solve Longest common prefix
class Solution : def longestCommonPrefix ( self , strs : List [ str ]) -> str : Longest_sum = "" for i in range ( len ( strs [ 0 ])): for j in st…
Tech news from the best sources
class Solution : def longestCommonPrefix ( self , strs : List [ str ]) -> str : Longest_sum = "" for i in range ( len ( strs [ 0 ])): for j in st…
class Solution : def twoSum ( self , nums : List [ int ], target : int ) -> List [ int ]: for i in range ( len ( nums )): for j in range ( len (…
Hoi hoi! I’m @nyaomaru , a frontend engineer who struggles to make game sounds. 😿 Have you used DSA View View already? 👀👀 I Built a Tool to Visualiz…
I built this app over the weekend as a side project. 🛠️ The problem was simple: after I submit on LeetCode, going back and forth to write notes and…
Hoi hoi! I’m @nyaomaru , a frontend engineer who dislikes crowded places, so I'm planning to take a quiet vacation in September. 🏝️ Have you used DS…
The Sliding Window pattern is one of the most vital algorithmic techniques for optimizing array and string problems. Instead of repeatedly processin…
Problem You are given an integer array arr. We split arr into some number of chunks (i.e., partitions), and individually sort each chunk. After conc…
Open the NeetCode 150 + Blind 75 tracker Somewhere around problem #40 of "just solving whatever LeetCode recommends," I realized I wasn't actually g…
Intuition Manacher's Algorithm leverages the symmetry of palindromes to avoid redundant comparisons. Instead of treating odd- and even-length palind…
If you've started learning DSA, you've probably run into the term STL more times than you can count. It sounds intimidating at first — but once it c…
Hi, DEV Community! 👋 I'm Khushi, and welcome to the beginning of my Data Structures and Algorithms (DSA) journey—again. You might be wondering, "Why…
In my last post, I covered arrays and strings and briefly touched on the two-pointer technique while reversing an array. That one example ended up b…
I am going to be honest with you. When everyone kept telling me Python was the "easy" language the beginner friendly one, the one you just pick up i…
After covering the foundational building blocks in Session 1, the next step is one of the most important problem-solving techniques in all of progra…
Competitive programming often looks like a race to write code as fast as possible. But the real secret is simpler: the best competitive programmers…
TLDR: I'm introducing Bit Flip, a newsletter where you get coding questions and interview questions asked by tech companies delivered to your inbox…
Most people learn data structures and algorithms the hard way: they open a problem site, sort by "most solved," and start grinding. A month later th…
For a long time, the standard advice for computer science students was simple: Learn a programming language, practice Data Structures and Algorithms…
As a third year student attending multiple internship drives and interviews, I started doubting my own worth ,is it all really confined to DSA? Does…
When tackling data structures and algorithms (DSA) problems, whether in technical interviews or competitive programming, engineers often overlook th…
3. Longest Substring Without Repeating Characters 🟡 Medium Hey Dev.to fam! 👋 Today, we're diving into a LeetCode classic that’s a fantastic introduc…
Let's discuss about while loop. We need to print a particular value say 5 for 10 times. print(5) print(5) print(5) print(5) print(5) print(5) print(…
Your First LeetCode Journey: Conquering 'Two Sum' (Problem 1) with Ease! Hey fellow developers! 👋 Kushalx here, and today we're diving into the abso…
🔄 LeetCode 1752: Can You Un-Rotate This Array? (A Beginner's Guide) Hey there, fellow coders! 👋 Vansh2710 here, ready to demystify another exciting…
Insertion Sort is the algorithm Python's Timsort uses for arrays under 64 elements . Not just a teaching tool — it's in production in the world's mo…
How to Conquer Roman Numerals: LeetCode #13 Explained Simply! Hey there, future coding superstar! 👋 Ever looked at Roman numerals and thought, "That…
Unraveling the Mystery of Roman Numerals: A LeetCode Journey (Problem 12. Integer to Roman) Hey LeetCoders and aspiring developers! 👋 Today, we're t…
Bubble Sort isn't used in production — but it's the best algorithm to learn sorting logic because every step is visible and intuitive. 🔹 The Idea Re…
The difference between linear and binary search is the difference between O(n) and O(log n) — which at scale means millions of operations vs 20 . 🔍…
3 Sum problem(2 pointer approach) Here,I discussed classic problem of both 3 Sum and 4 Sum problem. 3 Sum Problem Problem Statement Find all unique…