explaingit

labuladong/fucking-algorithm

133,470MarkdownAudience · developerComplexity · 1/5MaintainedSetup · easy

TLDR

A written guide to solving LeetCode problems by understanding the reasoning behind each solution, not just memorizing code. Includes tutorials on data structures and algorithms with links to practice problems.

Mindmap

mindmap
  root((repo))
    What it does
      LeetCode tutorials
      Algorithm explanations
      Data structure guides
    Learning approach
      Reasoning over memorization
      Worked examples
      Problem-solving patterns
    Tools and resources
      Visualization panel
      Browser plugins
      IDE extensions
    Topics covered
      Arrays and lists
      Trees and heaps
      Graphs
      Hash tables
    Use cases
      Interview prep
      Algorithm learning

Things people build with this

USE CASE 1

Prepare for coding interviews by learning algorithm patterns and how to approach unfamiliar problems.

USE CASE 2

Build a stronger foundation in data structures and algorithms through step-by-step explanations.

USE CASE 3

Practice LeetCode problems with guided solutions that teach reasoning, not just code snippets.

USE CASE 4

Use browser and IDE plugins to view relevant algorithm explanations while solving problems on LeetCode.

Tech stack

MarkdownLeetCode

Getting it running

Difficulty · easy Time to first run · 5min
License could not be detected automatically. Check the repository's LICENSE file before use.

In plain English

This repository is a written collection of algorithm tutorials by an author who goes by labuladong, framed around solving LeetCode problems. The description, in English, states the goal: crack LeetCode, not only by showing how a given problem is solved but also by explaining why. The author argues that practicing problems matters because it trains a way of thinking, not because it accumulates code snippets, and that copying clever one-line answers from comment sections does not actually teach you to reason through new problems. Practically, the repo points readers to a partner website where the same articles are organized as a structured course. Each article links to the matching LeetCode question so you can read the explanation and then attempt the problem. The author also describes companion tools: a visualization panel that animates data structures and recursion, and browser and editor plugins for Chrome, VS Code, and JetBrains IDEs that surface the relevant solution while you are looking at a problem. The table of contents lists chapters on language basics, complexity, and a wide range of data structures and algorithms, including arrays, linked lists, queues, stacks, hash tables, binary trees, binary heaps, tries, segment trees, and graph topics. You would use this repository if you are preparing for coding interviews or trying to build a more solid base in algorithms and data structures, especially if you prefer reading worked-through explanations alongside the actual problems. The articles are written in Markdown, with an English version available on the author's site.

Copy-paste prompts

Prompt 1
I'm preparing for a coding interview. Walk me through the labuladong algorithm tutorials on binary trees and explain the key patterns I should recognize.
Prompt 2
Show me how to use the labuladong visualization panel to understand how recursion works on a linked list problem.
Prompt 3
I'm stuck on a LeetCode problem about dynamic programming. Find the matching labuladong article and explain the reasoning behind the solution approach.
Prompt 4
Install the labuladong VS Code plugin and show me how to view algorithm explanations while I'm solving LeetCode problems.
Prompt 5
Explain the labuladong approach to learning algorithms: why understanding reasoning matters more than memorizing one-liner solutions.
Open on GitHub → Explain another repo

Generated 2026-05-18 · Model: sonnet-4-6 · Verify against the repo before relying on details.