Valid Anagram — Counting Characters in O(n)
A complete walkthrough of the Valid Anagram problem. Compare the sorting approach with the optimal hash map counting solution and learn how to explain it in interviews.
1745 posts · page 32 of 37
A complete walkthrough of the Valid Anagram problem. Compare the sorting approach with the optimal hash map counting solution and learn how to explain it in interviews.
A clean walkthrough of Valid Parentheses with the optimal stack solution. Covers edge cases, complexity, and how to explain the approach in interviews.
The seductive wrong answer, the correct min/max bounds approach, and how to defend it in an interview.
Solve Word Break with bottom-up dynamic programming. Includes brute force, edge cases, complexity analysis, and an interview script.
The wildcard-pattern adjacency trick, why BFS is mandatory, and the bidirectional speedup.
The essential math toolkit for interviews: Euclidean GCD, sieve of Eratosthenes, modular exponentiation, modular inverses, and common pitfalls.
Learn segment trees for fast range sum, min, and max queries with point updates, including a clean iterative Python implementation.
Compare Kahn's BFS-based topological sort with DFS-based postorder, with Python implementations, complexity, and cycle detection.
A practical introduction to tries: node structure, insert, search, prefix queries, memory tradeoffs, and classic interview problems like word search.
Learn the union-find data structure with union by rank and path compression, why it runs in near-O(1) amortized, and how it powers Kruskal and islands.
Learn Helm fundamentals: helm install, charts, values.yaml, templating, releases, and when to choose Helm over plain Kubernetes YAML manifests.
Master scheduled tasks on Linux. Learn crontab syntax, fix common PATH and environment pitfalls, and use systemd timers as a modern alternative.
A practical guide to modern Linux networking tools. Learn ip, ss, curl, and dig to diagnose connectivity, inspect sockets, and resolve DNS issues fast.
A practical tour of the Anthropic Python SDK: messages, streaming, tool use, prompt caching, and patterns for shipping Claude in production.
Learn LangChain by building real components in Python: prompt templates, chains, tool calling, and memory. Practical patterns you can ship today.
A practical tutorial on text embeddings: vector intuition, calling an embeddings API, choosing dimensions, computing cosine similarity, and caching the results.
A working tour of the OpenAI Python SDK: chat completions, streaming, structured output, embeddings, tool calls, and production-grade error handling.
Learn how logistic regression turns a linear score into a probability, how to train it with scikit-learn, and how to evaluate binary classifiers using ROC-AUC.
Master the Next.js Metadata API with static and dynamic titles, OpenGraph tags, sitemaps, and robots.txt to ship pages that rank and share well.
Use pgvector to run embeddings, similarity search, and hybrid retrieval inside Postgres. Schemas, indexes, and a working Python pipeline.
Build a working vector search pipeline with Pinecone in Python. Indexes, upserts, metadata filters, hybrid search, and patterns for production RAG.
A practical introduction to Python asyncio: the event loop, async/await, asyncio.run, gather, create_task, and when to pick async over threads.
A practical introduction to Python regex with the re module: match, search, findall, sub, groups, named groups, raw strings, and compiling patterns for speed.
Understand the Python GIL and pick the right concurrency tool: when threads help with I/O, when processes help with CPU, and how to use concurrent.futures.
Learn how TanStack Query replaces useEffect-based data fetching with caching, background refetching, and request deduplication that scales to real apps.
Learn React Router's modern data APIs. Install, create a browser router, define routes, navigate with Link and useNavigate, and use loaders and actions for data.
A clear, practical explanation of React Server Components: the runtime model, the boundary between server and client, data fetching, and the tradeoffs.
Use React.lazy and Suspense to code-split a React app, design fallback UI, place boundaries thoughtfully, and understand how Suspense extends to data fetching.
A practical guide to React's useMemo and useCallback hooks, covering referential equality, when memoization helps performance, when it backfires, and how to profile first.
Understand React's useReducer hook, its signature, action shape, when to migrate from useState, and how to build a small state machine pattern for predictable UI logic.
Skip the reducer boilerplate. Zustand gives React apps a tiny global store with hooks, selectors, and middleware in fewer than 100 lines of API.
A practical tour of Cargo — creating projects, managing dependencies and features, running tests, building release binaries, and using workspaces.
A hands-on tour of Rust's core collections — Vec, HashMap, and HashSet — with common operations, iteration patterns, and ownership gotchas.
A practical guide to error handling in Rust covering Result, the ? operator, unwrap and expect, custom error types, and the thiserror and anyhow crates.
Learn how to model domain data in Rust with structs and enums, use pattern matching exhaustively, and lean on Option and Result for safety.
Understand how Rust traits define shared behavior, with default methods, trait bounds, derive, and a clear take on dyn Trait versus impl Trait.
Learn how to read Postgres EXPLAIN and EXPLAIN ANALYZE output, spot expensive operations, and apply practical indexing and rewrite techniques to speed up queries.
A practical guide to database normalization with real customer and order examples. Covers 1NF, 2NF, 3NF, when to denormalize, and tradeoffs.
Learn SQL window functions with practical examples. Covers ROW_NUMBER, RANK, DENSE_RANK, LAG, LEAD, running totals, and the OVER clause in depth.
Design a distributed in-memory cache like Redis or Memcached. Covers consistent hashing, replication, eviction, persistence, and surviving node failures cleanly.
Design a layer 4 and layer 7 load balancer. Covers algorithms, health checks, sticky sessions, TLS termination, and surviving traffic spikes without dropping connections.
Design a durable message queue like Kafka or Pulsar. Covers partitions, replication, consumer groups, ordering guarantees, and exactly-once semantics in practice.
Design a URL shortener like TinyURL or Bit.ly. Covers ID generation, storage, read-heavy scaling, caching, analytics, and tradeoffs you should defend in an interview.
Set up dark mode in Tailwind with the class strategy, persist the choice in localStorage, and avoid the flash of wrong theme on first paint.
A practical look at integration testing alongside unit tests, covering fixtures, real databases in tests, and the right balance with examples in pytest and vitest.
A practical introduction to PWAs: manifests, service workers, offline caching, install prompts, and when a PWA is the right choice versus a native app.
A practical guide to the WCAG fundamentals: semantic HTML, keyboard support, contrast, focus management, and ARIA used responsibly.
What Largest Contentful Paint, Interaction to Next Paint, and Cumulative Layout Shift measure, how to read them, and the practical fixes that move each one.