Mohammad Taufeeq’s Post

Day 23 — Medium — Partition List Today’s problem was “Partition List.” At first, it wasn’t obvious how to rearrange nodes while keeping their relative order intact. I tried a few approaches but eventually had to look at the answer to understand the right method. Once I saw the solution, it clicked — building two separate lists (one for nodes smaller than the target value, and another for nodes greater or equal) and then connecting them gives the correct partition while preserving order. It took me a while, but after revisiting the explanation, I was able to crack the algorithm on my own. Key takeaway: Sometimes checking the answer isn’t failure — it’s just another step in learning. What matters is revisiting, rethinking, and making the solution your own. #100DaysOfCode #DSA #Java #LinkedLists #ProblemSolving #CodingJourney

  • No alternative text description for this image

To view or add a comment, sign in

Explore content categories