Catalog My learning Blog
Full-Stack Developer Course: React, .NET and SQL Server · Phase 10 · Lesson 99 · 10 min read

Full-Stack Developer Interview Preparation

On this page
  1. Learning Objective
  2. Concept Explanation
  3. Worked Example: Two Practical Problems and Concise Security Answers
  4. Real-World Examples
  5. Review Questions & Answers

Learning Objective

Prepare systematically for full-stack interviews by understanding what each round assesses, practicing coding problems in TypeScript and C# with a clear method, answering the recurring security and architecture questions concisely, structuring behavioral stories, and presenting your own project convincingly.

Concept Explanation

A full-stack interview loop usually contains four kinds of rounds, and each assesses something different. A coding round checks whether you can turn a problem into working code and reason about correctness and complexity. A frontend or backend practical round checks fluency in the stack: building a small React component or a small API endpoint. A system design round, using the framework of Day 91, checks how you structure open-ended problems, and a behavioral round checks collaboration, judgment, and how you handle failure. The strategy for each is to know what the interviewer is really scoring, which is rarely just the final answer. It is usually how you clarify, how you communicate your thinking, how you handle hints, how you test, and whether you show sound engineering judgment.

For coding problems, use a consistent method. Restate the problem and ask clarifying questions about inputs, sizes, edge cases, and constraints. Work a small example by hand. State a simple solution first, even a slow one, with its complexity, then improve it, naming the technique, such as a hash map, two pointers, a sliding window, a heap, or a graph traversal. Write clean code with meaningful names, then test it against your example and the edge cases out loud before the interviewer asks. Most topics recur: arrays and strings, hash maps, stacks and queues, linked structures, trees and graphs, sorting and searching, and basic dynamic programming. Gayle Laakmann McDowell's Cracking the Coding Interview has been the standard preparation guide since 2008 for a reason: it teaches the method as well as the problems.

Full-stack practicals test the specific skills of this course. For React, expect to build a debounced search box, an autocomplete, an infinite scroll list, a form with validation, or a small state-driven widget, and to discuss race conditions, cancellation, accessibility, and re-render behavior. For .NET and SQL, expect to write an endpoint with validation and error handling, a LINQ query, a SQL query with joins and grouping, and to explain async and await pitfalls, dependency injection lifetimes, the N+1 problem, and transaction isolation. Security questions appear in every loop for this kind of role, and you can answer them in a structured way: name the attack, explain how it works in one sentence, and give the layered defenses. Practice saying these aloud in under a minute each, because being concise and correct is a skill separate from knowing the material.

Behavioral rounds reward preparation as much as any technical round. Build a bank of six to eight real stories, using the situation, task, action, and result structure, that cover a technical challenge, a disagreement, a mistake or outage and what you changed afterward, a time you improved something without being asked, a time you influenced without authority, and a time you handled ambiguity. Amazon's published leadership principles are used in behavioral interviews at that company and give a useful set of themes even elsewhere: ownership, customer focus, dive deep, and bias for action. Include stories about security and quality decisions, since they signal seniority. Prepare a five-minute walk-through of your capstone project: the problem, the architecture, two or three decisions with their trade-offs, one thing that went wrong and what you learned, and what you would do next. Finally, prepare questions for the interviewer about their engineering practices, on-call, testing, and how they handle security, since your questions are evaluated too.

RoundWhat is assessedHow to prepare
CodingProblem solving, correctness, communicationPractice the method on core topics, test aloud
Frontend practicalReact fluency, state, async, accessibilityBuild the classic components from scratch under time
Backend practicalAPI design, validation, data access, errorsWrite endpoints with tests, know EF and SQL well
System designStructure, estimation, trade-offs, securityUse the Day 91 framework on many prompts
BehavioralJudgment, collaboration, learning from failureStory bank in STAR form, including a failure
Project deep diveOwnership and depth of your own workFive-minute walkthrough and answers on every decision

Worked Example: Two Practical Problems and Concise Security Answers

The first problem is a sliding-window rate limiter in C# with tests, the second a debounced search hook in React that avoids stale results, and the last block gives model short answers to common questions.

C#
// Problem: implement a rate limiter that allows at most N requests per key in any window of W seconds.
// Clarify: per key? thread safety? memory growth? Approach: keep a queue of timestamps per key, drop expired ones.
public sealed class SlidingWindowLimiter(int limit, TimeSpan window, TimeProvider clock)
{
    private readonly Dictionary<string, Queue<DateTimeOffset>> _hits = new();
    private readonly object _gate = new();

    public bool TryAcquire(string key)
    {
        var now = clock.GetUtcNow();
        lock (_gate)                                                     // simple and correct; discuss sharded locks or Redis for scale
        {
            if (!_hits.TryGetValue(key, out var q)) _hits[key] = q = new Queue<DateTimeOffset>();
            while (q.Count > 0 && now - q.Peek() >= window) q.Dequeue();   // evict timestamps outside the window: O(1) amortized
            if (q.Count >= limit) return false;
            q.Enqueue(now);
            return true;
        }
    }
    // Complexity: O(1) amortized per call, O(limit) memory per active key.
    // Follow-ups to volunteer: evict idle keys to bound memory, use a token bucket for bursts, move state to Redis for many instances.
}

public class SlidingWindowLimiterTests
{
    [Fact]
    public void Allows_up_to_the_limit_then_blocks_until_the_window_passes()
    {
        var clock = new FakeTimeProvider(); var l = new SlidingWindowLimiter(3, TimeSpan.FromSeconds(10), clock);
        Assert.True(l.TryAcquire("a")); Assert.True(l.TryAcquire("a")); Assert.True(l.TryAcquire("a"));
        Assert.False(l.TryAcquire("a"));                                 // 4th within the window
        Assert.True(l.TryAcquire("b"));                                  // other keys are independent
        clock.Advance(TimeSpan.FromSeconds(10));
        Assert.True(l.TryAcquire("a"));                                  // the window has passed
    }
}
TypeScript
// Problem: a search box that queries as you type. Requirements to state: debounce, cancel stale requests, handle errors, no stale results.
function useDebouncedValue<T>(value: T, delayMs: number) {
  const [debounced, setDebounced] = useState(value);
  useEffect(() => {
    const id = setTimeout(() => setDebounced(value), delayMs);
    return () => clearTimeout(id);                                       // reset the timer on every keystroke
  }, [value, delayMs]);
  return debounced;
}

export function Search() {
  const [text, setText] = useState('');
  const term = useDebouncedValue(text.trim(), 300);

  const { data, isFetching, error } = useQuery({
    queryKey: ['search', term],
    queryFn: ({ signal }) => request(`/api/search?q=${encodeURIComponent(term)}`, ResultsSchema, { signal }),   // aborted when the term changes
    enabled: term.length >= 2,
    staleTime: 30_000,
  });

  return (
    <div role="search">
      <label htmlFor="q">Search</label>
      <input id="q" value={text} onChange={(e) => setText(e.target.value)} aria-busy={isFetching} autoComplete="off" />
      {error && <p role="alert">Search failed. Try again.</p>}
      <ul aria-live="polite">{data?.items.map((r) => <li key={r.id}>{r.title}</li>)}</ul>   {/* text is escaped by React */}
    </div>
  );
}
// Talking points: why debounce (fewer requests), why AbortSignal (an old slow response must not overwrite a newer one),
// why encodeURIComponent, why the results are text and not HTML, why the API also rate limits and caps query length.
Code
MODEL ANSWERS: under one minute each. Attack, mechanism, layered defense.

"How do you prevent XSS?"
  Injected script runs in the victim's page with their privileges. Defense in layers: never insert untrusted data as HTML,
  rely on React's escaping and avoid dangerouslySetInnerHTML, sanitize any rich text with an allowlist library, validate URL
  schemes, send a strict Content Security Policy, and keep tokens in HttpOnly cookies so script cannot steal them.

"Explain CORS and CSRF. Does CORS protect against CSRF?"
  CORS lets a server allow specific other origins to READ its responses; it is not access control. CSRF abuses cookies sent
  automatically to make state-changing requests. CORS does not stop it. Use SameSite cookies, anti-forgery tokens or a custom
  header, Fetch Metadata checks, and never reflect the Origin header with credentials.

"How do you prevent SQL injection?"
  Parameterize every query so input is data, not code; EF Core LINQ does it automatically, FromSql only with interpolation.
  Allowlist identifiers that cannot be parameters, use a least-privilege database login, and test with attack strings.

"JWT in localStorage or cookie?"
  localStorage is readable by any script, so XSS steals the token for reuse anywhere. An HttpOnly, Secure, SameSite cookie
  is not readable by script, so I prefer a cookie session through a backend-for-frontend, with CSRF protection, and keep tokens on the server.

"How do you make an endpoint safe to retry?"
  Idempotency: PUT and DELETE are naturally idempotent; for POST accept an Idempotency-Key, store the first result per user
  and key, return it on repeats, and reject reuse with a different body.

"What is the N+1 problem and how do you find it?"
  One query loads N rows and then one more query runs per row for related data. Find it by logging SQL or reading traces; fix it with
  a projection or eager loading so one or two queries return everything.
Code
BEHAVIORAL STORY BANK (write each as Situation, Task, Action, Result, and Lesson in 6 to 8 sentences)
1. A hard technical problem you solved (the N+1 or the slow query, with numbers before and after)
2. A disagreement you resolved (an architecture choice; how you used data and a decision record)
3. A mistake or incident and what you changed (blameless, concrete follow-ups)
4. Something you improved without being asked (the CI check, the test, the runbook)
5. A time you handled unclear requirements (how you clarified and de-risked)
6. A security or quality decision that cost time now and saved risk later (the authorization matrix, the migration rehearsal)
Practice aloud. Aim for two minutes each. Have the Day 100 capstone as story 7 with a five-minute walkthrough.

Practice in the format you will be tested in: timed, aloud, with a shared editor, ideally with another person acting as the interviewer. Recording yourself and reviewing the recording is uncomfortable and by far the fastest way to improve how clearly you communicate.

For coding rounds: clarify, work an example, state a simple solution, optimize, code, and test aloud. Prepare concise security answers as attack, mechanism and layered defense, and a bank of STAR stories including a failure.
For coding rounds: clarify, work an example, state a simple solution, optimize, code, and test aloud. Prepare concise security answers as attack, mechanism and layered defense, and a bank of STAR stories including a failure.

Real-World Examples

  • Gayle Laakmann McDowell's Cracking the Coding Interview, first published in 2008 and updated several times since, laid out the standard approach still used by candidates: clarify, work examples, find a brute force solution, optimize, then code and test. Its detailed description of how large companies evaluate candidates helped standardize expectations about communication and method in technical interviews.
  • Amazon publishes its leadership principles, such as Ownership, Customer Obsession, Dive Deep, and Bias for Action, and uses them to structure behavioral interview questions, expecting candidates to answer with specific past examples. Many other companies use similar frameworks, so preparing a bank of concrete stories that map to such principles is useful well beyond one employer.
Key TakeawaysKnow what each round assesses and use a consistent method: clarify, example, simple solution, optimize, code, test aloud. Practice the classic React and .NET practicals, prepare concise attack, mechanism, and defense answers for security questions, build a STAR story bank including a failure, and rehearse a five-minute walkthrough of your capstone, practicing in the real format and reviewing recordings.

Review Questions & Answers

Restate the problem, ask clarifying questions about inputs, sizes, and edge cases, and work a small example by hand. This confirms you understand the task, surfaces hidden requirements, and gives you a test case to verify your solution against, and interviewers score this communication as part of your performance.

Responses can arrive out of order, so a slow response for an old term could arrive after a newer one and overwrite the correct results. Aborting the stale request, through the AbortSignal supplied by the query library, and keying results by term ensures the display always matches the current input.

Name the attack, explain in a sentence how it works, then list layered defenses, showing that no single control is relied on. For example, for XSS explain script injection, then give escaping, sanitization, URL validation, a Content Security Policy, and HttpOnly cookies. Concise, structured answers show depth without rambling.

Interviewers want evidence of judgment, honesty, and learning, and everyone who has operated systems has caused or witnessed failures. A specific story that owns the problem, explains the response, and names the concrete changes made afterward demonstrates maturity and a blameless, improvement-focused approach.