I Knew DSA But Couldn't Solve Problems

How changing my approach from concepts to patterns completely changed my DSA journey.

Satvik Sharma
Satvik Sharma
4 min readJun 24, 2026
I Knew DSA But Couldn't Solve Problems

When I started learning DSA during my college days, my preparation strategy was exactly what most people recommend.

  • Learn a concept.
  • Write notes on paper.
  • Practice a few questions.
  • Move to the next topic.

Arrays.

Linked Lists.

Stacks.

Queues.

Trees.

Graphs.

Dynamic Programming.

Everything felt organized.

I had notebooks full of notes. I knew the theory. I remembered the time complexities. I could even explain concepts to my friends.

At that point, I genuinely believed I was making progress.

But slowly something started happening.

As I moved to newer topics, I began forgetting older ones.

So naturally, I started revising.

Again.

And again.

And again.


Concepts fading from memory


Even after revision, there was one problem.

Questions were not getting solved.

Whenever I opened a new problem on LeetCode, my mind simply went blank.

I knew HashMaps.

I knew heaps.

I knew sorting.

I knew time complexities.

Yet I had no idea where to begin.

At first, I thought the issue was revision.

Maybe I had forgotten the concepts.

So I revised everything again.

The result was exactly the same.

That was when I realized something important.

I had learned DSA concept wise.

But interviews ask questions pattern wise.

Companies do not ask:

"Explain HashMap."

Instead, they ask:

"Solve this problem."

And your job is to recognize the underlying pattern.


Placement interview pressure


That realization completely changed my preparation strategy.

I started learning about patterns.

  • Sliding Window
  • Two Pointers
  • Prefix Sum
  • Binary Search
  • Top K Elements
  • Monotonic Stack
  • Backtracking
  • Greedy
  • Dynamic Programming patterns

For the first time, things started making sense.

I stopped asking:

"Which concept is this?"

And started asking:

"Which pattern is this problem following?"

That single shift changed everything.


Discovering DSA patterns


Since I already knew the concepts, I stopped spending all my time revising theory.

Instead, I started directly solving questions.

For example, I picked Top K Frequent Elements.

I gave myself 25 minutes.

No YouTube.

No editorial.

No hints.

I simply wrote whatever came to my mind.

Sometimes it was brute force.

Sometimes it was partially optimized.

Sometimes it was completely wrong.

But I realized that struggling with a problem teaches more than watching ten solution videos.

After writing my code, I used AI to review it.

I would ask questions like:

  • Why is this approach slow?
  • What bottlenecks exist?
  • Can this be optimized?
  • Which data structure would work better?
  • What am I missing?

Only after understanding my mistakes would I ask for the optimal solution.

This process taught me far more than simply memorizing answers.


AI assisted learning


Today, my approach looks like this:

  1. Pick a pattern.
  2. Solve multiple questions from that pattern.
  3. Give yourself enough time to think.
  4. Write the brute force solution first.
  5. Review your code.
  6. Understand the optimization.
  7. Move to the next problem.

The biggest lesson I learned is this:

Concepts teach you the tools.

Patterns teach you when to use those tools.

You can know every data structure and every algorithm.

But if you cannot recognize patterns, interviews will still feel difficult.

And if you are currently feeling that DSA is impossible despite studying for months, maybe the problem is not your effort.

Maybe the problem is simply the approach.

Because in DSA, knowing is very different from solving.

And solving is what interviews actually test.


Final realization


Final Thoughts

If I could go back and advise my college self, I would say only one thing:

Learn concepts once.

Practice patterns many times.

Because interviews do not test how much theory you remember.

They test whether you can recognize a problem and solve it.

And that skill comes only from patterns and practice.