<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: sarah</title>
    <description>The latest articles on DEV Community by sarah (@sarah23).</description>
    <link>https://dev.to/sarah23</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4127267%2F34e38a9f-224f-46a8-a42d-fc1e3a756306.png</url>
      <title>DEV Community: sarah</title>
      <link>https://dev.to/sarah23</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/sarah23"/>
    <language>en</language>
    <item>
      <title>Design a rate limiter, answered properly</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Fri, 23 Oct 2026 15:11:53 +0000</pubDate>
      <link>https://dev.to/sarah23/design-a-rate-limiter-answered-properly-4a2g</link>
      <guid>https://dev.to/sarah23/design-a-rate-limiter-answered-properly-4a2g</guid>
      <description>&lt;p&gt;Design a rate limiter, answered properly&lt;br&gt;
This is the most common system design question I was asked, and the one where the follow ups do all the work. Here is the full walkthrough, including the parts I got wrong first.&lt;/p&gt;

&lt;p&gt;Written after being asked this four times in one year. Updated October 2026. 9 min read&lt;/p&gt;

&lt;p&gt;Design a rate limiter came up in four separate processes in one year. The first time I described token bucket in ninety seconds and then sat there, having used up what I knew. The remaining forty minutes were where the round actually happened.&lt;/p&gt;

&lt;p&gt;The algorithm is the easy part and everyone gets there. The round is decided after that.&lt;br&gt;
Clarify before you draw&lt;br&gt;
Four questions, about ninety seconds.&lt;/p&gt;

&lt;p&gt;What are we protecting?&lt;br&gt;
A public API, a login endpoint, an expensive operation. The answer changes the limits.&lt;br&gt;
Limited by what?&lt;br&gt;
Per user, per API key, per IP address, or globally. Each has different problems.&lt;br&gt;
What scale?&lt;br&gt;
Hundreds of requests a second or hundreds of thousands changes the storage answer.&lt;br&gt;
What should happen at the limit?&lt;br&gt;
Reject, queue, or degrade. Rejecting is usually right but it is worth asking.&lt;br&gt;
The algorithms, and when each fits&lt;br&gt;
Pick one and defend it.&lt;/p&gt;

&lt;p&gt;Allows&lt;br&gt;
bursts&lt;br&gt;
Memory cheap&lt;br&gt;
Exact&lt;br&gt;
Simple to&lt;br&gt;
explain&lt;br&gt;
Token bucket&lt;br&gt;
Limited&lt;br&gt;
Sliding window log&lt;br&gt;
n/a&lt;br&gt;
n/a&lt;br&gt;
Limited&lt;br&gt;
Fixed window&lt;br&gt;
Limited&lt;br&gt;
n/a&lt;br&gt;
Leaky bucket&lt;br&gt;
n/a&lt;br&gt;
Limited&lt;br&gt;
Limited&lt;br&gt;
Clearly fits&lt;br&gt;
Sometimes&lt;br&gt;
Not the tool for this&lt;br&gt;
Token bucket is the usual default. Say why you picked it rather than just naming it.&lt;br&gt;
Token bucket holds a number of tokens that refill at a fixed rate. Each request takes one. An empty bucket means rejection. It allows a short burst up to the bucket size, which matches how real clients behave, and it is cheap to store as two numbers per key.&lt;/p&gt;

&lt;p&gt;Fixed window is simpler and has one notorious flaw worth raising yourself: a client can send a full allowance at the end of one window and another full allowance at the start of the next, producing double the intended rate across that boundary.&lt;/p&gt;

&lt;p&gt;Making it work across many servers&lt;br&gt;
The first real follow up.&lt;/p&gt;

&lt;p&gt;In process counters stop working the moment you run more than one instance, because each server only sees its own share of traffic. Move the counters to a shared fast store keyed by the identity and the window.&lt;/p&gt;

&lt;p&gt;The subtlety to raise unprompted is atomicity. Reading the count, deciding, and writing it back as three separate steps lets two servers both allow the final request. Use an atomic increment or a small script that performs the check and update as one operation.&lt;/p&gt;

&lt;p&gt;What you return at the limit&lt;br&gt;
The part that affects real clients.&lt;/p&gt;

&lt;p&gt;A good rejection&lt;br&gt;
429 status code&lt;br&gt;
A header with the limit&lt;br&gt;
A header with remaining quota&lt;br&gt;
A retry after hint&lt;br&gt;
A bad rejection&lt;br&gt;
A generic 500&lt;br&gt;
No indication of when to retry&lt;br&gt;
Silently dropping the request&lt;br&gt;
A different shape from your normal errors&lt;br&gt;
Without a retry hint, a well intentioned client retries immediately and your rate limiter becomes a generator of additional load. This is the detail that separates someone who has designed one from someone who has read about one.&lt;/p&gt;

&lt;p&gt;When the counter store is down&lt;br&gt;
The follow up that decides the round.&lt;/p&gt;

&lt;p&gt;You have two options and both are defensible. Failing open keeps traffic flowing while losing protection, which suits a general API where availability matters most. Failing closed protects the service while rejecting legitimate users, which suits a login endpoint where the limiter is a security control.&lt;/p&gt;

&lt;p&gt;The answer interviewers want is not one of the two. It is that you know there is a choice, you know what each one costs, and you can say which you would pick for this specific endpoint.&lt;/p&gt;

&lt;p&gt;Extras worth mentioning if time allows&lt;br&gt;
Briefly, not exhaustively.&lt;/p&gt;

&lt;p&gt;Different limits per tier&lt;br&gt;
Free and paid users rarely share a limit.&lt;br&gt;
Local plus shared&lt;br&gt;
A small in process cache reduces round trips at high volume.&lt;br&gt;
Observability&lt;br&gt;
Which metric tells you the limiter is wrongly configured rather than working.&lt;br&gt;
Testing it&lt;br&gt;
How you would verify the limit without hammering production.&lt;br&gt;
How I practised this question&lt;br&gt;
Design it, then remove something.&lt;/p&gt;

&lt;p&gt;After my second time being asked, I started designing it on paper and then deleting a component: the shared store, one of the servers, the retry header. I used Phantom Code AI[&lt;a href="https://www.phantomcodeai.com/" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/&lt;/a&gt;] in its slower reasoning mode to attack my design rather than produce one, specifically asking what breaks when two servers race for the last token. That race condition was consistently the weak point in my own version.&lt;/p&gt;

&lt;p&gt;Since the same tool covers coding, SQL and behavioural rounds, the evening habit carried the rest of the loop rather than being a single question exercise.&lt;/p&gt;

&lt;p&gt;Common questions&lt;br&gt;
Short answers.&lt;/p&gt;

&lt;p&gt;Which algorithm should I pick?&lt;br&gt;
How does it work across servers?&lt;br&gt;
What should the API return?&lt;br&gt;
What if the store is down?&lt;br&gt;
Everyone gets the algorithm. Few get the failure modes.&lt;br&gt;
This question survives in every loop because the first ninety seconds are easy and the next twenty minutes are not. Burst behaviour, races, retry hints and store outages are where it is decided.&lt;/p&gt;

&lt;p&gt;Sketch it tonight, then delete the shared store and write what happens next.&lt;/p&gt;

&lt;p&gt;Written after the fourth time, finally enjoying it&lt;/p&gt;

&lt;p&gt;How many times have you been asked this one?&lt;/p&gt;

&lt;p&gt;Four, for me, and the follow ups were different every time.&lt;/p&gt;

</description>
      <category>architecture</category>
      <category>backend</category>
      <category>interview</category>
      <category>systemdesign</category>
    </item>
    <item>
      <title>The follow up email is short, specific, and sent the same day</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Wed, 21 Oct 2026 13:35:59 +0000</pubDate>
      <link>https://dev.to/sarah23/the-follow-up-email-is-short-specific-and-sent-the-same-day-1cl0</link>
      <guid>https://dev.to/sarah23/the-follow-up-email-is-short-specific-and-sent-the-same-day-1cl0</guid>
      <description>&lt;p&gt;The follow up email is short, specific, and sent the same day&lt;br&gt;
Most advice about this is either far too long or tells you not to bother. Here is what I send, when I send it, and what to do about the silence that follows.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/..." class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/..." alt="Uploading image" width="800" height="400"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Written after over thinking a four sentence email for an hour. Updated October 2026. 6 min read&lt;/p&gt;

&lt;p&gt;Thanks for today&lt;br&gt;
Hi Priya,&lt;br&gt;
Thanks for your time today. I enjoyed&lt;br&gt;
the rate limiter discussion, especially&lt;br&gt;
the point about per user versus global.&lt;br&gt;
Happy to answer anything further.&lt;br&gt;
Best, Sam&lt;br&gt;
WHEN TO SEND WHAT&lt;br&gt;
Same day&lt;br&gt;
short thank you&lt;br&gt;
Day 7&lt;br&gt;
polite check in&lt;br&gt;
Day 14&lt;br&gt;
one final nudge&lt;br&gt;
After that&lt;br&gt;
move on, quietly&lt;br&gt;
Four sentences, one specific detail, and no pressure anywhere in it.&lt;br&gt;
The short version: send four sentences the same day, including one specific detail from the conversation so it could not have been written in advance. Then wait roughly a week before a polite check in, and about a fortnight before one final short message. After that, keep applying elsewhere and let it go.&lt;/p&gt;

&lt;p&gt;Company norms vary. The timing below is a reasonable default rather than a rule.&lt;/p&gt;

&lt;p&gt;I spent an hour on four sentences&lt;br&gt;
And nearly did not send them.&lt;/p&gt;

&lt;p&gt;My first thank you email went through about six drafts. The version I sent was four sentences long, took forty seconds to write once I stopped editing, and got a reply within the hour mentioning a detail I had raised.&lt;/p&gt;

&lt;p&gt;I have no idea whether it changed the outcome. What I do know is that the hour of agonising added nothing to the email.&lt;/p&gt;

&lt;p&gt;The email is not an argument for hiring you. It is a short, human acknowledgement of someone making time for you.&lt;br&gt;
The four sentences&lt;br&gt;
Same day, before you forget the detail.&lt;/p&gt;

&lt;p&gt;1&lt;br&gt;
Thanks&lt;br&gt;
One line. Name the&lt;br&gt;
person, name the&lt;br&gt;
day.&lt;br&gt;
2&lt;br&gt;
One detail&lt;br&gt;
Something specific&lt;br&gt;
from the&lt;br&gt;
conversation.&lt;br&gt;
3&lt;br&gt;
One line of interest&lt;br&gt;
Why the role still&lt;br&gt;
appeals, briefly.&lt;br&gt;
4&lt;br&gt;
An open door&lt;br&gt;
Happy to answer&lt;br&gt;
anything further.&lt;br&gt;
Four lines. Anything longer starts to read as a pitch.&lt;br&gt;
The specific detail is the part that matters. It proves the message was written after the conversation rather than before it, and it quietly reminds them which candidate you were.&lt;/p&gt;

&lt;p&gt;What not to include&lt;br&gt;
All of these have been suggested to me and all of them are worse.&lt;/p&gt;

&lt;p&gt;Works&lt;br&gt;
Four short sentences&lt;br&gt;
One concrete detail&lt;br&gt;
Sent within a few hours&lt;br&gt;
Plain subject line&lt;br&gt;
Backfires&lt;br&gt;
A summary of your qualifications&lt;br&gt;
Attaching extra work nobody asked for&lt;br&gt;
Correcting an answer at length&lt;br&gt;
Anything that mentions how badly you want it&lt;br&gt;
The correction one deserves a caveat. If you got something factually wrong and the fix is one sentence, including it is fine and occasionally impressive. Three paragraphs relitigating a design decision is not.&lt;/p&gt;

&lt;p&gt;The waiting part&lt;br&gt;
Which is harder than the writing.&lt;/p&gt;

&lt;p&gt;Ask for a timeline&lt;br&gt;
At the end of the interview, so you are not guessing later.&lt;br&gt;
Wait the stated time&lt;br&gt;
Then a day or two more, then check in.&lt;br&gt;
One polite check in&lt;br&gt;
Two sentences. Still interested, any update, no pressure.&lt;br&gt;
One final message&lt;br&gt;
A week later. Then stop and keep applying.&lt;br&gt;
What silence usually means&lt;br&gt;
Rarely what it feels like.&lt;/p&gt;

&lt;p&gt;Silence after an interview is almost always internal. A panel member is on leave, the role is being re-scoped, another candidate is mid process, or someone simply forgot. It occasionally means a no that nobody has written up yet. It very rarely means anything about you personally, even though it feels extremely personal when it is your week.&lt;/p&gt;

&lt;p&gt;The practical response is to assume nothing, send your two messages on schedule, and keep other processes moving so that this one is not carrying all your hope.&lt;/p&gt;

&lt;p&gt;After a rejection&lt;br&gt;
One short reply, which costs nothing.&lt;/p&gt;

&lt;p&gt;Thank them, say you enjoyed the conversation, and ask whether there is anything specific you could improve. Many companies will decline to say. The ones who answer usually give you one precise sentence, and that sentence is worth more than a week of guessing.&lt;/p&gt;

&lt;p&gt;When the feedback named a round rather than a quality, which it usually did for me, that was the thing to go and drill. I used Phantom Code AI[&lt;a href="https://www.phantomcodeai.com/" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/&lt;/a&gt;] for that, since rotating between coding, system design, SQL and behavioral practice in one place made it easy to spend a fortnight on whichever round the feedback pointed at rather than starting a whole new routine.&lt;/p&gt;

&lt;p&gt;Common questions&lt;br&gt;
Short answers.&lt;/p&gt;

&lt;p&gt;Should I send a thank you email?&lt;br&gt;
How long before following up?&lt;br&gt;
What if there is no reply?&lt;br&gt;
Should I ask for feedback after a no?&lt;br&gt;
Short, specific, and then let it go&lt;br&gt;
The follow up is one of the few parts of a job search you fully control, which is exactly why people overwork it. Four sentences, one detail, and then your attention belongs to the next application.&lt;/p&gt;

&lt;p&gt;Write your template tonight so that after your next interview it takes two minutes rather than an hour.&lt;/p&gt;

&lt;p&gt;Written after finally sending the first draft&lt;/p&gt;

&lt;p&gt;Do you send thank you emails?&lt;/p&gt;

&lt;p&gt;I was convinced they were pointless until one got a reply.&lt;/p&gt;

</description>
      <category>career</category>
      <category>networking</category>
      <category>productivity</category>
    </item>
    <item>
      <title>Beating Coding Interview Anxiety: Focus Techniques That Actually Work</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Tue, 20 Oct 2026 04:16:35 +0000</pubDate>
      <link>https://dev.to/sarah23/beating-coding-interview-anxiety-focus-techniques-that-actually-work-5aim</link>
      <guid>https://dev.to/sarah23/beating-coding-interview-anxiety-focus-techniques-that-actually-work-5aim</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F804f9jmxzs41pz42g7dj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F804f9jmxzs41pz42g7dj.png" alt=" " width="456" height="230"&gt;&lt;/a&gt;&lt;br&gt;
Beating Coding Interview Anxiety: Focus Techniques That Actually Work&lt;br&gt;
You know the material, yet your mind goes blank the moment the interviewer says go. That is not a talent problem; it is a stress response. The good news is that it is trainable.&lt;/p&gt;

&lt;p&gt;Why you freeze&lt;br&gt;
Under perceived threat the body releases adrenaline, working memory shrinks and recall gets harder. Interviews are evaluative and observed, which is precisely the situation that triggers this. Knowing the mechanism helps: you are not stupid, you are stressed.&lt;/p&gt;

&lt;p&gt;Performance versus stress: the sweet spot&lt;br&gt;
Performance versus stress: the sweet spot&lt;br&gt;
Technique one: rehearse under mild pressure&lt;br&gt;
Practice with a timer, out loud, with a friend watching or a recording running. Exposure reduces the threat response. Increase difficulty gradually: first alone, then with a peer, then with a stranger in a mock interview.&lt;/p&gt;

&lt;p&gt;Technique two: use a script for the first two minutes&lt;br&gt;
Starting is the hardest part. Memorize an opening routine: restate the problem, ask two clarifying questions, give an example, and describe a brute-force approach. This keeps you moving while your brain warms up.&lt;/p&gt;

&lt;p&gt;Technique three: regulate your body&lt;br&gt;
Slow exhale breathing, four seconds in and six seconds out, lowers heart rate within a minute. Do it before joining the call and again whenever you feel stuck. Sleep, caffeine moderation and a short walk beforehand matter more than last-minute cramming.&lt;/p&gt;

&lt;p&gt;A four-step reset when your mind goes blank&lt;br&gt;
A four-step reset when your mind goes blank&lt;br&gt;
Technique four: reframe the silence&lt;br&gt;
Interviewers expect pauses. Say, let me think for a moment, and take them. Treat hints as collaboration rather than failure. If you blank, go back to a small example and trace it by hand; the pattern usually appears.&lt;/p&gt;

&lt;p&gt;Technique five: build evidence of competence&lt;br&gt;
Keep a log of solved problems and good mock sessions. Reading it before an interview reminds you of real evidence. Tools can help here too: reviewing a transcript of a practice session, such as one captured with Phantom Code AI[&lt;a href="https://www.phantomcodeai.com/" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/&lt;/a&gt;], shows exactly where you hesitated and what worked.&lt;/p&gt;

&lt;p&gt;After a bad round&lt;br&gt;
Write what happened, extract two lessons, and move on within an hour. One round rarely defines an outcome, and many offers follow imperfect interviews.&lt;/p&gt;

&lt;p&gt;Build a practice routine, add a rehearsal partner like the one at phantomcode.co and follow each employer's assistance rules.&lt;/p&gt;

</description>
      <category>career</category>
      <category>interview</category>
      <category>productivity</category>
    </item>
    <item>
      <title>Dynamic Programming Without the Panic</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Fri, 16 Oct 2026 17:06:43 +0000</pubDate>
      <link>https://dev.to/sarah23/dynamic-programming-without-the-panic-1hj3</link>
      <guid>https://dev.to/sarah23/dynamic-programming-without-the-panic-1hj3</guid>
      <description>&lt;p&gt;Dynamic Programming Without the Panic&lt;br&gt;
DP is recursion plus memory.&lt;/p&gt;

&lt;p&gt;Ask a room of candidates what they dread most and dynamic programming usually wins. The name sounds grand, the solutions look like magic, and the fear is that you either remember the trick or you do not. That fear makes people freeze, which is a much bigger problem than the material itself.&lt;/p&gt;

&lt;p&gt;Here is the calmer view: dynamic programming is recursion with memory. If you can write a plain recursive solution, you are already most of the way there. This post shows a sequence of small steps, from brute force to cache to table, plus a way to recognize the classic families so that new problems feel familiar.&lt;/p&gt;

&lt;p&gt;Try Deep Think →&lt;br&gt;
Begin with the slow recursive answer&lt;br&gt;
Forget tables for now. Write the most natural recursive solution, even if it is exponential. For climbing a staircase where you can take one or two steps, the number of ways to reach step n is the ways to reach n minus one plus the ways to reach n minus two. Base cases are one way for step zero and one way for step one.&lt;/p&gt;

&lt;p&gt;Running this by hand for n equal to five shows the same calls repeating: step three is computed several times. That repetition is the signal. You say to the interviewer, subproblems overlap, so caching should help, and you have already demonstrated the core insight.&lt;/p&gt;

&lt;p&gt;Do not rush to optimize. A correct brute force on the page is worth more than a half remembered table. It also gives you a reference you can use to test the faster version on small inputs.&lt;/p&gt;

&lt;p&gt;Add a cache and you are done&lt;br&gt;
Create a dictionary or array keyed by the arguments of the recursive function. At the start of the function, return the stored value if it exists. Before returning a computed value, store it. That is memoization, and for many interviews it is a complete answer.&lt;/p&gt;

&lt;p&gt;State the complexity clearly: each distinct state is computed once, and each computation does a small amount of work, so total time is the number of states times the work per state. For the staircase that is linear time and linear space, down from exponential time.&lt;/p&gt;

&lt;p&gt;Key the cache on every argument that changes&lt;br&gt;
Check the cache first, store before returning&lt;br&gt;
Count states times work per state for complexity&lt;br&gt;
Define the state in one sentence&lt;br&gt;
Before writing code, finish this sentence: dp of i and j means the best result when I have considered the first i items and have j left. If you cannot finish it, you are not ready to code. A vague state is the root cause of most wrong DP answers.&lt;/p&gt;

&lt;p&gt;For coin change, a good sentence is: dp of amount is the fewest coins needed to make that amount. The transition follows naturally, because you try each coin and take the minimum of one plus dp of amount minus coin. Writing the sentence also gives you the base case, which is dp of zero equals zero.&lt;/p&gt;

&lt;p&gt;Some people write the state sentence as a comment above the function. That one line keeps you honest when you are under time pressure, and it gives the interviewer a clear view of your thinking.&lt;/p&gt;

&lt;p&gt;Convert to a table only when it helps&lt;br&gt;
A bottom up table avoids recursion depth limits and can shrink memory. Fill states in an order where dependencies are already known. For coin change, loop amounts from one up to the target and look back at smaller amounts.&lt;/p&gt;

&lt;p&gt;Often the table can be trimmed. If each row depends only on the previous row, keep two rows instead of all of them. Mention this as an optimization after your correct solution, not before. Interviewers value a correct memoized answer over a half finished clever table.&lt;/p&gt;

&lt;p&gt;Study hard problems, then solve them yourself&lt;br&gt;
When a problem is beyond your current level, use it as a case study. Phantom Code AI offers a Deep Think mode built for harder algorithm problems, so you can look at how a tough DP breaks into state, transition, and base case, then close the explanation and re-solve it from scratch. The desktop app runs on macOS and Windows and has a free trial.&lt;/p&gt;

&lt;p&gt;The re-solve step matters most. Reading a solution creates a false sense of understanding. Keep it as a study and practice aid, and respect the rules of your employer and any test provider during real assessments. Afterward, add the problem to a family list so you can spot its relatives.&lt;/p&gt;

&lt;p&gt;A walkthrough: climbing to coin change&lt;br&gt;
Take amounts of 11 with coins 1, 2, and 5. The recursive idea is that the fewest coins for 11 is one plus the minimum of the fewest for 10, 9, and 6. Many of those smaller amounts appear more than once, such as 6 and 5, so a cache pays off right away.&lt;/p&gt;

&lt;p&gt;Bottom up, fill an array from 0 to 11. Position 0 is 0. Position 1 is 1, position 2 is 1, position 3 is 2, and so on until position 11 comes out to 3, using 5, 5, and 1. Mark unreachable amounts with a large sentinel and return negative one if the target stays unreachable.&lt;/p&gt;

&lt;p&gt;This pattern, an array indexed by a quantity and a loop over choices, shows up in dozens of problems. Once you have written it by hand, you can adapt it to counting ways, or to fewest steps.&lt;/p&gt;

&lt;p&gt;Define the array meaning in a comment&lt;br&gt;
Choose a sentinel for impossible states&lt;br&gt;
Fill in an order that respects dependencies&lt;br&gt;
Return the right cell, and handle unreachable cases&lt;br&gt;
Frequently asked questions&lt;br&gt;
How do I know a problem needs DP?&lt;br&gt;
Look for optimization or counting over choices where the same smaller situation recurs. Phrases like number of ways, minimum cost, longest, and can you reach are common hints, especially when a greedy choice fails on a small example.&lt;/p&gt;

&lt;p&gt;Top down or bottom up in an interview?&lt;br&gt;
Start top down because it mirrors your reasoning and is quicker to get right. Move to bottom up if the interviewer asks about recursion depth or space.&lt;/p&gt;

&lt;p&gt;Which problem families should I memorize?&lt;br&gt;
Know knapsack, longest common subsequence, edit distance, and coin change well. Most other questions are disguised versions of these four shapes.&lt;/p&gt;

&lt;p&gt;Final thoughts&lt;br&gt;
Dynamic programming is a three step habit: write the recursion, notice the repeats, add memory. The panic fades once you stop hunting for a trick and start with the plain version every time.&lt;/p&gt;

&lt;p&gt;Keep a short list of families you have solved, with the state sentence for each. Review it weekly and add one new problem at a time. In a few weeks, most questions will look like old friends in new clothes.&lt;/p&gt;

&lt;p&gt;Try Deep Think →&lt;/p&gt;

&lt;p&gt;Learn more at Phantom Code AI.[&lt;a href="https://phantomcode.co/" rel="noopener noreferrer"&gt;https://phantomcode.co/&lt;/a&gt;]&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F9sq76702em4nrzajfukh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F9sq76702em4nrzajfukh.png" alt=" " width="456" height="230"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Use any interview tool in line with your employer's and test provider's rules.&lt;/p&gt;

</description>
      <category>algorithms</category>
      <category>beginners</category>
      <category>computerscience</category>
      <category>programming</category>
    </item>
    <item>
      <title>"We had good coverage" is the weakest answer in the round</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Wed, 14 Oct 2026 15:57:50 +0000</pubDate>
      <link>https://dev.to/sarah23/we-had-good-coverage-is-the-weakest-answer-in-the-round-18g0</link>
      <guid>https://dev.to/sarah23/we-had-good-coverage-is-the-weakest-answer-in-the-round-18g0</guid>
      <description>&lt;p&gt;what deserves a test, what does not, and how you know the suite is telling you the truth. Coverage percentages answer none of that.&lt;/p&gt;

&lt;p&gt;Written after an answer that was a number and nothing else. Updated October 2026. 7 min read&lt;/p&gt;

&lt;p&gt;Where the tests should live&lt;br&gt;
end to end, few&lt;br&gt;
integration&lt;br&gt;
unit, many and fast&lt;br&gt;
WHAT THEY ASK&lt;br&gt;
what would you test here?&lt;br&gt;
what would you not test?&lt;br&gt;
how do you test the failure?&lt;br&gt;
what makes a test flaky?&lt;br&gt;
The short version: say what you would test and what you deliberately would not, put most tests at the fast end, test the failure paths rather than only the happy one, and have an opinion about flaky tests. A candidate who can say what is not worth testing sounds far more experienced than one quoting coverage.&lt;/p&gt;

&lt;p&gt;Team practices vary widely. Defend your own with reasons rather than rules.&lt;/p&gt;

&lt;p&gt;The number that answered nothing&lt;br&gt;
"Our coverage was around eighty percent."&lt;/p&gt;

&lt;p&gt;It was true and it told the interviewer nothing. Coverage measures which lines ran, not whether anything was checked. The follow up, which I had no answer for, was simple: which part of that system were you most afraid of, and what did you do about it.&lt;/p&gt;

&lt;p&gt;Coverage says what was executed. The interview is about what was verified.&lt;br&gt;
What to say instead&lt;br&gt;
Risk first, shape second.&lt;/p&gt;

&lt;p&gt;1&lt;br&gt;
Name the risk&lt;br&gt;
Which part would&lt;br&gt;
hurt most if it&lt;br&gt;
broke quietly?&lt;br&gt;
2&lt;br&gt;
Pick the level&lt;br&gt;
Unit for logic,&lt;br&gt;
integration for&lt;br&gt;
wiring, end to end&lt;br&gt;
sparingly.&lt;br&gt;
3&lt;br&gt;
Test the failure&lt;br&gt;
Timeouts, bad input,&lt;br&gt;
partial writes.&lt;br&gt;
4&lt;br&gt;
Keep it honest&lt;br&gt;
Delete tests that&lt;br&gt;
never fail and fix&lt;br&gt;
ones that fail&lt;br&gt;
randomly.&lt;br&gt;
Four moves that turn a coverage answer into a judgement answer.&lt;br&gt;
What not to test&lt;br&gt;
The part that signals experience.&lt;/p&gt;

&lt;p&gt;Usually worth testing&lt;br&gt;
Business rules and edge cases&lt;br&gt;
Data transformations&lt;br&gt;
Error and retry paths&lt;br&gt;
Anything that has broken before&lt;br&gt;
Usually not worth it&lt;br&gt;
Framework behaviour&lt;br&gt;
Simple getters and setters&lt;br&gt;
Exact log strings&lt;br&gt;
Private methods through reflection&lt;br&gt;
Flaky tests are a trust problem&lt;br&gt;
Say that out loud.&lt;/p&gt;

&lt;p&gt;One test that fails randomly teaches an entire team to rerun the pipeline without reading it. That habit then hides a real failure. Quarantine first so trust survives, then fix the cause, which is nearly always time, test ordering or shared state between tests.&lt;/p&gt;

&lt;p&gt;Testing the failure path&lt;br&gt;
The question candidates skip.&lt;/p&gt;

&lt;p&gt;Timeouts&lt;br&gt;
What does your code do when the dependency never answers?&lt;br&gt;
Partial writes&lt;br&gt;
Half the batch succeeded. Is that state recoverable?&lt;br&gt;
Bad input&lt;br&gt;
Not just invalid, but plausible and wrong.&lt;br&gt;
Retries&lt;br&gt;
Does retrying twice produce two of something?&lt;br&gt;
If your current team has no tests&lt;br&gt;
Answer honestly and move to the plan.&lt;/p&gt;

&lt;p&gt;Saying that your team ships without tests, followed by which single path you would cover first and why, reads far better than inventing a culture you did not have. Interviewers are mostly checking whether you have an opinion and whether you would improve things without demanding a rewrite.&lt;/p&gt;

&lt;p&gt;How I practised the discussion&lt;br&gt;
Out loud, on real code.&lt;/p&gt;

&lt;p&gt;I took functions from my own projects and talked through what I would test and skip, with a timer. For the rest of the loop, the algorithm round and the behavioral round, I used Phantom Code AI[&lt;a href="https://www.phantomcodeai.com/" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/&lt;/a&gt;] nightly, attempting first and comparing second. Having coding, system design, SQL and behavioral practice in one place meant the craft discussions above were the only thing I had to rehearse separately.&lt;/p&gt;

&lt;p&gt;Common questions&lt;br&gt;
Short answers.&lt;/p&gt;

&lt;p&gt;Unit versus integration?&lt;br&gt;
Is high coverage a good goal?&lt;br&gt;
How do you handle flaky tests?&lt;br&gt;
What if your job has no tests?&lt;br&gt;
Have an opinion, not a percentage&lt;br&gt;
The strongest testing answers I have heard were specific about what the person chose not to test. That is the sentence that separates judgement from compliance.&lt;/p&gt;

&lt;p&gt;Take one function you wrote this week and say out loud what deserves a test and what does not.&lt;/p&gt;

&lt;p&gt;Written after learning that eighty percent is not an answer&lt;/p&gt;

&lt;p&gt;What is the most useful test you ever wrote?&lt;/p&gt;

&lt;p&gt;Mine caught a timezone bug that would have been invisible.&lt;/p&gt;

</description>
      <category>career</category>
      <category>interview</category>
      <category>testing</category>
    </item>
    <item>
      <title>Every design round asked me about caching. Few of them asked directly.</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Tue, 13 Oct 2026 12:12:44 +0000</pubDate>
      <link>https://dev.to/sarah23/every-design-round-asked-me-about-caching-few-of-them-asked-directly-5cib</link>
      <guid>https://dev.to/sarah23/every-design-round-asked-me-about-caching-few-of-them-asked-directly-5cib</guid>
      <description>&lt;p&gt;Every design round asked me about caching. Few of them asked directly.&lt;br&gt;
The question arrives as latency, cost or load, and the answer is almost always a cache plus a story about what happens when it is wrong.&lt;/p&gt;

&lt;p&gt;Written after a design round that stalled on invalidation. Updated October 2026. 8 min read&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F0il4nyj7juy63s2sgj68.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F0il4nyj7juy63s2sgj68.png" alt=" " width="558" height="202"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;One request, two outcomes&lt;br&gt;
client&lt;br&gt;
cache&lt;br&gt;
database&lt;br&gt;
only on a miss&lt;br&gt;
HIT, most of the time&lt;br&gt;
2 ms&lt;br&gt;
MISS, occasionally&lt;br&gt;
90 ms&lt;br&gt;
The short version: adding a cache is easy and interviewers know it. The marks are in what you say about staleness, eviction, what happens when many requests miss the same key at once, and how you would know the cache is helping. Say the hit rate you expect and what you would do if it came back at fifty percent.&lt;/p&gt;

&lt;p&gt;The numbers in the illustration are typical shapes, not measurements of any specific system.&lt;/p&gt;

&lt;p&gt;The follow up that ended a round&lt;br&gt;
"What happens when the data changes?"&lt;/p&gt;

&lt;p&gt;I had drawn a clean design with a cache in front of the database and felt good about it. The interviewer asked how a price update reaches a user who already has a cached page, and I produced the word invalidation and then nothing useful.&lt;/p&gt;

&lt;p&gt;Anybody can add a cache. The interview is about what you do when it is wrong.&lt;br&gt;
The four things to say&lt;br&gt;
In this order.&lt;/p&gt;

&lt;p&gt;1&lt;br&gt;
What you cache&lt;br&gt;
The exact key, and&lt;br&gt;
why that&lt;br&gt;
granularity.&lt;br&gt;
2&lt;br&gt;
How it is filled&lt;br&gt;
Cache aside, read&lt;br&gt;
through, or write&lt;br&gt;
through.&lt;br&gt;
3&lt;br&gt;
How it goes stale&lt;br&gt;
Time to live,&lt;br&gt;
explicit&lt;br&gt;
invalidation, or&lt;br&gt;
both.&lt;br&gt;
4&lt;br&gt;
What breaks&lt;br&gt;
Stampedes, hot keys,&lt;br&gt;
memory pressure.&lt;br&gt;
Four sentences that cover most caching follow ups.&lt;br&gt;
Staleness is a product decision&lt;br&gt;
Say that out loud.&lt;/p&gt;

&lt;p&gt;How stale is acceptable depends on what the data is. A product description can be minutes old. A bank balance cannot. Asking what the acceptable staleness window is, before choosing a strategy, shows you treat correctness as a requirement rather than a default.&lt;/p&gt;

&lt;p&gt;Usually fine when stale&lt;br&gt;
Product descriptions&lt;br&gt;
Search result lists&lt;br&gt;
Recommendations&lt;br&gt;
Public profile pages&lt;br&gt;
Usually not fine&lt;br&gt;
Account balances&lt;br&gt;
Inventory at checkout&lt;br&gt;
Permissions and roles&lt;br&gt;
Anything used for a safety decision&lt;br&gt;
Eviction and the failure modes&lt;br&gt;
The vocabulary interviewers expect.&lt;/p&gt;

&lt;p&gt;Least recently used&lt;br&gt;
A sensible default when recent access predicts future access.&lt;br&gt;
Time to live&lt;br&gt;
Simple, and it bounds how wrong you can be.&lt;br&gt;
Cache stampede&lt;br&gt;
Many misses on one hot key at once. Coalesce requests or stagger expiry.&lt;br&gt;
Hot key&lt;br&gt;
One key taking a disproportionate share of traffic, which can overwhelm a single node.&lt;br&gt;
How would you know it is working&lt;br&gt;
The question nobody prepares for.&lt;/p&gt;

&lt;p&gt;Name the metrics before being asked: hit rate, latency at the ninety fifth percentile with and without the cache, and database load. Then say what each number would make you do. A hit rate of fifty percent usually means your key is wrong or your time to live is too short, not that caching does not help here.&lt;/p&gt;

&lt;p&gt;How I practised design follow ups&lt;br&gt;
Design it, then attack it.&lt;/p&gt;

&lt;p&gt;My routine was to sketch a design on paper and then have it attacked rather than extended. I used Phantom Code AI[ in its slower reasoning mode for that, describing my cache placement and asking specifically what breaks when a key goes hot or when the data changes mid request. The invalidation story was reliably my weak point. Because it also handles coding, SQL and behavioral practice, the same evening habit carried the rest of the loop.&lt;/p&gt;

&lt;p&gt;Common questions&lt;br&gt;
Short answers.&lt;/p&gt;

&lt;p&gt;Main strategies?&lt;br&gt;
Why is invalidation hard?&lt;br&gt;
Eviction policies?&lt;br&gt;
What is a stampede?&lt;br&gt;
Cache answers are about being wrong well&lt;br&gt;
Adding the box is the trivial part of a design. This question survives in every loop because the interesting part is what happens at the edges.&lt;/p&gt;

&lt;p&gt;Take any design you have sketched and write one sentence about what happens when the underlying data changes.&lt;/p&gt;

&lt;p&gt;Written after an invalidation question I now enjoy&lt;/p&gt;

&lt;p&gt;What is the worst cache bug you have seen?&lt;/p&gt;

&lt;p&gt;Mine served one customer another customer's dashboard.&lt;/p&gt;

</description>
      <category>architecture</category>
      <category>interview</category>
      <category>scalability</category>
      <category>systemdesign</category>
    </item>
    <item>
      <title>Best Affordable AI Assistant in 2027 for Your Budget</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Fri, 09 Oct 2026 03:57:57 +0000</pubDate>
      <link>https://dev.to/sarah23/best-affordable-ai-assistant-in-2027-for-your-budget-1dc9</link>
      <guid>https://dev.to/sarah23/best-affordable-ai-assistant-in-2027-for-your-budget-1dc9</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F8657l90snitg1yrbmxyn.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F8657l90snitg1yrbmxyn.png" alt=" " width="577" height="237"&gt;&lt;/a&gt;&lt;br&gt;
Meta description: Compare AI assistant costs for 2027 by checking the features you need, actual usage, renewal terms, and the total payment commitment.&lt;/p&gt;

&lt;p&gt;Research date: 7 October 2026 | Forward-looking guide for 2027&lt;/p&gt;

&lt;p&gt;The best affordable AI assistant in 2027 should provide useful help at a cost that fits your actual use. The cheapest advertised rate may not be the cheapest option once separate features, limited allowances, or a longer billing commitment are included.&lt;/p&gt;

&lt;p&gt;Begin with a simple list of the tasks you expect to use it for. Estimate how often you will complete those tasks and which features are essential. This makes a price comparison more meaningful.&lt;/p&gt;

&lt;p&gt;Hypothetical example, not vendor pricing. A 1200 budget divided by six completed sessions is 200 per session; three sessions make it 400.&lt;/p&gt;

&lt;p&gt;Compare the full payment&lt;/p&gt;

&lt;p&gt;Look at the amount charged and the period it covers. A monthly equivalent can look attractive while requiring a larger payment upfront. Decide whether you need the service for a brief project or expect sustained use.&lt;/p&gt;

&lt;p&gt;Check renewal, cancellation, and any expiry rules. If payment is in another currency, use the actual payment quote and applicable charges when assessing the cost to you.&lt;/p&gt;

&lt;p&gt;Use a realistic denominator&lt;/p&gt;

&lt;p&gt;Consider a hypothetical pack costing 1200 in your budgeting currency. Completing six sessions makes the cost 200 per used session. Completing three makes it 400. These figures illustrate the calculation and are not an offer from a vendor.&lt;/p&gt;

&lt;p&gt;For a general assistant, the denominator could be useful work sessions or completed tasks. The point is to connect spending to the activity you actually finish and benefit from.&lt;/p&gt;

&lt;p&gt;Confirm which feature the price includes&lt;/p&gt;

&lt;p&gt;Specialist products may sell different activities separately. PhantomCodeAI's[&lt;a href="https://www.phantomcodeai.com/" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/&lt;/a&gt;] live-assistant pricing and practice interview pricing are separate pages to inspect when budgeting for interview-related use.&lt;/p&gt;

&lt;p&gt;Do not assume that unlimited access in one category includes every service the company offers. Confirm the specific feature at checkout before making a commitment.&lt;/p&gt;

&lt;p&gt;Start with evidence from your own trial&lt;/p&gt;

&lt;p&gt;Complete a representative task and record how much correction the result required. A low price is less useful if the output repeatedly creates more work than it removes.&lt;/p&gt;

&lt;p&gt;For a 2027 decision, check current offers again when you are ready to buy. Choose a commitment that fits your likely usage and gives you room to reassess after you have enough experience with the service.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Best AI Assistant for Personal Productivity in 2027</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Wed, 07 Oct 2026 15:53:16 +0000</pubDate>
      <link>https://dev.to/sarah23/best-ai-assistant-for-personal-productivity-in-2027-2gd5</link>
      <guid>https://dev.to/sarah23/best-ai-assistant-for-personal-productivity-in-2027-2gd5</guid>
      <description>&lt;p&gt;Research date: 7 October 2026 | Forward-looking guide for 2027&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fye93g8oy3lb19odgkjr2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fye93g8oy3lb19odgkjr2.png" alt=" " width="462" height="195"&gt;&lt;/a&gt;&lt;br&gt;
The best AI assistant for productivity in 2027 should help you make realistic choices about your time. Generating a longer task list is easy. A useful assistant helps you decide what fits today, what needs clarification, and what can wait.&lt;/p&gt;

&lt;p&gt;Start with the commitments already on your calendar. Then add the tasks you hope to complete and a rough estimate of the effort involved. A plan built without those constraints can look organized while being impossible to follow.&lt;/p&gt;

&lt;p&gt;A suggested planning process. Fixed commitments and available time determine how much work belongs in the day.&lt;/p&gt;

&lt;p&gt;Separate commitments from preferences&lt;/p&gt;

&lt;p&gt;A scheduled meeting and a task you would like to finish are different kinds of obligations. Tell the assistant which deadlines are fixed, which are flexible, and which depend on someone else's response.&lt;/p&gt;

&lt;p&gt;Ask it to identify conflicts before producing a schedule. If two tasks both require the same uninterrupted hour, the plan needs a decision rather than smaller text inside the same time slot.&lt;/p&gt;

&lt;p&gt;Define a useful next action&lt;/p&gt;

&lt;p&gt;Replace broad items such as work on presentation with a concrete step, such as draft the opening argument or check the three figures. Smaller actions make it easier to start and easier to tell whether the work is complete.&lt;/p&gt;

&lt;p&gt;Ask the assistant to preserve room for interruptions. The amount of spare time depends on your day, but a schedule that assumes everything goes perfectly should be treated as an optimistic scenario.&lt;/p&gt;

&lt;p&gt;Keep the plan connected to your goals&lt;/p&gt;

&lt;p&gt;Productivity includes preparation for future opportunities. If an interview is approaching, give it a defined practice block rather than leaving it as an indefinite task. PhantomCodeAI's [&lt;a href="https://www.phantomcodeai.com/mock-interview" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/mock-interview&lt;/a&gt;] mock interview options are one resource to review for that specific activity.&lt;/p&gt;

&lt;p&gt;Keep general planning separate from the service used to carry out each task. A planning assistant does not need to be the same tool you use for writing, studying, or interview practice.&lt;/p&gt;

&lt;p&gt;Review the plan after using it&lt;/p&gt;

&lt;p&gt;At the end of the day, note what took longer than expected and what was interrupted. Use those observations to improve the next plan. Avoid treating an unfinished list as proof that you need a more complicated productivity system.&lt;/p&gt;

&lt;p&gt;When choosing a tool for 2027, look for easy corrections, understandable priorities, and a workflow you can maintain. The useful result is a day with clear choices and enough flexibility to respond when circumstances change.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>productivity</category>
      <category>tools</category>
    </item>
    <item>
      <title>Dynamic Programming Interviews and the Meaning of a State</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Mon, 05 Oct 2026 14:47:42 +0000</pubDate>
      <link>https://dev.to/sarah23/dynamic-programming-interviews-and-the-meaning-of-a-state-3j8g</link>
      <guid>https://dev.to/sarah23/dynamic-programming-interviews-and-the-meaning-of-a-state-3j8g</guid>
      <description>&lt;p&gt;Dynamic Programming Interviews and the Meaning of a State Define the state and the stopping point&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fxmkktzxg64xpbxpuyh7x.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fxmkktzxg64xpbxpuyh7x.png" alt=" " width="526" height="238"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Let dp[a] mean the fewest coins needed to make exactly amount a using the permitted denominations. The word exactly matters. A solution that exceeds the target does not satisfy this problem.&lt;/p&gt;

&lt;p&gt;The base case is dp[0] equal to zero because making zero requires no coins. Other states begin as unreachable. You can represent that with a suitable sentinel, but explain how your arithmetic avoids treating the sentinel as an ordinary count.&lt;/p&gt;

&lt;p&gt;Assume the denominations are positive integers and the target is a nonnegative integer. A zero or negative denomination would undermine the simple dependency order used by this solution. Clarifying that assumption is part of defining the problem.&lt;/p&gt;

&lt;p&gt;Derive the recurrence from the last coin&lt;/p&gt;

&lt;p&gt;Imagine an optimal solution for amount a and consider its last coin c. The remaining coins must make a minus c. If that remainder could be made with fewer coins than the solution used, replacing it would improve the original solution as well.&lt;/p&gt;

&lt;p&gt;This motivates trying every allowed last coin and taking the smallest reachable value of dp[a minus c] plus one. Only consider coins that do not exceed a. The recurrence is a consequence of the choice you are enumerating, rather than a formula that appears without explanation.&lt;/p&gt;

&lt;p&gt;For this example, the answers for amounts zero through six are 0, 1, 2, 1, 1, 2, and 2. At amount six, using a final coin of three reaches dp[3] plus one, giving two coins.&lt;/p&gt;

&lt;p&gt;Evaluate the states in a safe order&lt;/p&gt;

&lt;p&gt;Fill amounts from zero upward. Every positive coin leads to a smaller remainder, so the states needed for amount a have already been computed. If the interviewer changes the problem to limited coin quantities, this state definition may no longer contain enough information.&lt;/p&gt;

&lt;p&gt;Distinguish minimum coin count from the number of ways to form an amount. Both questions mention coins, but they aggregate possibilities differently. Reusing a remembered loop without checking the objective can solve a different problem convincingly.&lt;/p&gt;

&lt;p&gt;Handle missing answers and reconstruct a solution&lt;/p&gt;

&lt;p&gt;Try denominations 3 and 4 with target 2. No combination works, so the state stays unreachable. Your final output should report that outcome explicitly instead of returning the sentinel as a coin count.&lt;/p&gt;

&lt;p&gt;If the interviewer wants the actual coins, record which choice produced each reachable minimum. Starting at the target, follow those choices back to zero. Tie-breaking can be arbitrary unless the output contract requires a specific combination.&lt;/p&gt;

&lt;p&gt;You can use PhantomCodeAI[&lt;a href="https://www.phantomcodeai.com/download" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/download&lt;/a&gt;] as one preparation resource, but ask for a critique of your state definition before requesting completed code. A useful follow-up is to change the supply from unlimited to limited and explain why the original state needs reconsideration.&lt;/p&gt;

&lt;p&gt;With target T and K denominations, this bottom-up method examines up to K choices for each amount, using O(TK) time and O(T) storage. State those parameters clearly. The explanation should connect the state, choices, base case, and evaluation order into one argument.&lt;/p&gt;

</description>
      <category>algorithms</category>
      <category>computerscience</category>
      <category>interview</category>
      <category>programming</category>
    </item>
    <item>
      <title>Low Level Design Interviews and the Rules Behind a Parking Lot</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Fri, 02 Oct 2026 14:20:45 +0000</pubDate>
      <link>https://dev.to/sarah23/low-level-design-interviews-and-the-rules-behind-a-parking-lot-71</link>
      <guid>https://dev.to/sarah23/low-level-design-interviews-and-the-rules-behind-a-parking-lot-71</guid>
      <description>&lt;p&gt;A parking lot question can tempt candidates to start listing classes immediately: Vehicle, Ticket, Gate, Floor, and Payment. A list of nouns is easy to produce. A low level design interview becomes more interesting when you explain which object owns a decision and which rules must survive every operation.&lt;/p&gt;

&lt;p&gt;Begin with a small scope: vehicles enter, receive a compatible spot, and leave after their parking session is closed. Add reservations, pricing variations, or multiple gates only when the interviewer requests them. The exercise is to build a coherent model, not to guess every feature a real facility might someday need.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fxsks81xzqlbsb2268zya.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fxsks81xzqlbsb2268zya.png" alt=" " width="501" height="248"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Simplified parking spot lifecycle for the article. Each transition must preserve the allocation rule.&lt;/p&gt;

&lt;p&gt;Write the rules before the classes&lt;/p&gt;

&lt;p&gt;One spot cannot belong to two active parking sessions at the same time. A vehicle should not receive a spot it cannot use. A completed session should not be closed again as if it were a new departure. These are invariants, and they tell you where the design needs protection.&lt;/p&gt;

&lt;p&gt;Decide what identifies a session and what information must persist. A ticket number may refer to a session containing vehicle details, entry time, assigned spot, and status. A spot records its capabilities and availability. Payment records can remain separate so financial state does not become a boolean scattered across unrelated objects.&lt;/p&gt;

&lt;p&gt;Put behavior beside the state it protects&lt;/p&gt;

&lt;p&gt;An allocation service can select a compatible available spot. However, selection and claiming cannot be two uncoordinated operations when multiple gates are active. Explain how a repository or transaction boundary makes the claim atomic. The exact mechanism depends on whether the exercise is in memory or backed by a database.&lt;/p&gt;

&lt;p&gt;Avoid allowing every caller to set spot status directly. Provide operations that enforce allowed transitions and return an explicit failure when a transition is invalid. This gives tests a clear contract and reduces the number of places that must remember the rules.&lt;/p&gt;

&lt;p&gt;The diagram uses available, held, and occupied states. A hold can expire if entry is not completed. If the initial requirements do not need reservations, the hold can be a short internal allocation step rather than a public booking feature.&lt;/p&gt;

&lt;p&gt;Make extension points earn their place&lt;/p&gt;

&lt;p&gt;If pricing varies by vehicle type or time of day, a pricing policy can calculate a charge from a completed session. Keep that calculation separate from opening a gate. If the question has one fixed rate, a straightforward function may be enough until variation is introduced.&lt;/p&gt;

&lt;p&gt;Similarly, an allocation policy can later prefer the nearest compatible spot. You do not need a design pattern name to justify the separation. Explain the behavior that is likely to change and the data it requires. That is more useful than adding interfaces to every class by default.&lt;/p&gt;

&lt;p&gt;PhantomCodeAI's[&lt;a href="https://www.phantomcodeai.com/interview-types/system-design-interview" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/interview-types/system-design-interview&lt;/a&gt;] system design resources describe both high level and low level design coverage. For this exercise, focus your rehearsal on object responsibilities and invalid operations instead of scaling the system to millions of requests.&lt;/p&gt;

&lt;p&gt;Walk through the awkward cases&lt;/p&gt;

&lt;p&gt;Ask what happens when two gates try to claim the last spot, a ticket is scanned twice, payment succeeds but the exit action fails, or a held spot is never occupied. You do not need to implement every recovery mechanism during the interview. You do need to show where each outcome is represented.&lt;/p&gt;

&lt;p&gt;Test the model through its public operations. A successful allocation reduces available capacity exactly once. A rejected allocation changes nothing. Closing an already closed session has a defined result. These examples reveal the design more clearly than a large class diagram alone.&lt;/p&gt;

&lt;p&gt;Finish by tracing one entry and one departure. The interviewer should be able to follow the state changes and see which component is responsible for preserving each rule.&lt;/p&gt;

</description>
      <category>interview</category>
      <category>softwareengineering</category>
      <category>systemdesign</category>
    </item>
    <item>
      <title>How to Prepare for a Software Engineering Interview With AI</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Wed, 30 Sep 2026 14:20:27 +0000</pubDate>
      <link>https://dev.to/sarah23/how-to-prepare-for-a-software-engineering-interview-with-ai-2hpb</link>
      <guid>https://dev.to/sarah23/how-to-prepare-for-a-software-engineering-interview-with-ai-2hpb</guid>
      <description>&lt;p&gt;AI can make software engineering interview preparation more efficient if it improves how you practice. A schedule with unaided attempts, targeted feedback, and spaced review works better than asking for solutions whenever a question gets difficult.&lt;/p&gt;

&lt;p&gt;Week 1: Diagnose&lt;/p&gt;

&lt;p&gt;Take two timed coding problems, a short design prompt, and three behavioral questions. Speak your reasoning aloud. After each attempt, ask an assistant to identify unclear assumptions and missing edge cases. Verify technical comments with tests or references. Write down the top three recurring weaknesses.&lt;/p&gt;

&lt;p&gt;Week 2: Work on the bottleneck&lt;/p&gt;

&lt;p&gt;If you miss patterns, group problems by technique and ask for variants. If communication is the issue, practice stating an approach before coding. If design is weak, rehearse requirements, scale estimates, APIs, and tradeoffs. Use the tool for hints only after a fixed independent attempt.&lt;/p&gt;

&lt;p&gt;Week 3: Simulate the interview&lt;/p&gt;

&lt;p&gt;Run timed mocks without pausing to ask for answers. Review transcripts or notes afterward. Ask for a concise critique with examples from what you actually said. PhantomCodeAI[&lt;a href="https://www.phantomcodeai.com/" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/&lt;/a&gt;]&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fpj1891b77ei6pyq8rqkw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fpj1891b77ei6pyq8rqkw.png" alt=" " width="542" height="281"&gt;&lt;/a&gt; is one product that describes audio-supported coding and interview practice; test whether its workflow helps you find and fix your specific errors.&lt;/p&gt;

&lt;p&gt;Week 4: Consolidate&lt;/p&gt;

&lt;p&gt;Repeat earlier prompts and compare outcomes. Add one or two human mocks. Prepare questions for the interviewer and review the employer's assessment rules. Avoid cramming entirely new topics in the final days unless a job description makes them essential.&lt;/p&gt;

&lt;p&gt;The plan is adjustable. A candidate with only one week should still preserve the same cycle: attempt, feedback, correction, retest. AI is most useful when the final retest happens without it.&lt;/p&gt;

&lt;p&gt;FAQ: Should I memorize AI-generated answers? No. Use them to inspect structure, then produce an answer based on your own reasoning and experience.&lt;/p&gt;

</description>
      <category>career</category>
      <category>interview</category>
      <category>productivity</category>
      <category>softwareengineering</category>
    </item>
    <item>
      <title>One week until the interview. Fix one thing properly instead of everything badly.</title>
      <dc:creator>sarah</dc:creator>
      <pubDate>Fri, 25 Sep 2026 14:51:01 +0000</pubDate>
      <link>https://dev.to/sarah23/one-week-until-the-interview-fix-one-thing-properly-instead-of-everything-badly-3gng</link>
      <guid>https://dev.to/sarah23/one-week-until-the-interview-fix-one-thing-properly-instead-of-everything-badly-3gng</guid>
      <description>&lt;p&gt;Cramming four topics in seven days leaves you shallow in all of them. This plan spends more than half the week on the single round most likely to fail you.&lt;/p&gt;

&lt;p&gt;Written after two rushed weeks, one good and one bad · Updated September 2026 · 7 min read&lt;/p&gt;

&lt;p&gt;Seven days is not enough to learn everything. It is enough to fix one thing properly.&lt;br&gt;
The short version: day seven is an honest audit, days six to four go entirely on your weakest round, day three is one mock with a person, day two is your stories and questions, and day one is rest and logistics. Seven days is enough to fix one thing, and that is usually enough.&lt;/p&gt;

&lt;p&gt;If you have four weeks, do this plan and then repeat the middle section. If you have two days, skip to the last three rows.&lt;/p&gt;

&lt;p&gt;The week I wasted&lt;br&gt;
Four topics, seven days, nothing learned.&lt;/p&gt;

&lt;p&gt;My first crash week looked productive. A bit of dynamic programming, a bit of system design, some SQL, a few behavioral notes. On the day, the system design round exposed that I had skimmed rather than understood, and everything else I had touched was equally thin.&lt;/p&gt;

&lt;p&gt;The second time, I gave more than half the week to the one round I dreaded. It was the only round that went well, and it was enough.&lt;/p&gt;

&lt;p&gt;Seven days buys depth in one place or shallowness everywhere. Choose on day seven.&lt;br&gt;
Day 7: the audit&lt;br&gt;
One timed attempt per round type.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Feb9gwif28npi2auk4gs1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Feb9gwif28npi2auk4gs1.png" alt=" " width="566" height="266"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The one you avoided scheduling is usually the weakest.&lt;br&gt;
Days 6 to 4: the weak round&lt;br&gt;
Three days on one thing.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F0ws7k73mw7r1xpbqfntn.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F0ws7k73mw7r1xpbqfntn.png" alt=" " width="546" height="237"&gt;&lt;/a&gt;&lt;br&gt;
Three days is enough to move one round from panic to competent.&lt;br&gt;
This is where a practice tool earns its place, because you need volume and instant feedback rather than a person. I used Phantom Code AI  [&lt;a href="https://www.phantomcodeai.com/%5Dfor" rel="noopener noreferrer"&gt;https://www.phantomcodeai.com/]for&lt;/a&gt; these three days, attempting first and then comparing the approach and complexity, and its slower mode for the system design version of this plan. Covering SQL and behavioral rounds in the same tool mattered during a short week, since I had no time to assemble a toolkit.&lt;/p&gt;

&lt;p&gt;Day 3: one mock with a person&lt;br&gt;
The part you cannot fake alone.&lt;/p&gt;

&lt;p&gt;A friend, a colleague, anyone willing to interrupt you. Ask them to push back once, ask "why" twice, and tell you afterwards what your delivery was like. This single session reliably produced my biggest fixes, usually about pace rather than content.&lt;/p&gt;

&lt;p&gt;Day 2: stories and questions&lt;br&gt;
Low effort, high return.&lt;/p&gt;

&lt;p&gt;Prepare&lt;br&gt;
Two project stories: problem, decision, result&lt;br&gt;
One failure story you have actually processed&lt;br&gt;
Three questions to ask them&lt;br&gt;
A 60 second background answer&lt;br&gt;
Skip&lt;br&gt;
New topics&lt;br&gt;
Reading interview horror stories&lt;br&gt;
Rewriting your resume&lt;br&gt;
Anything that raises anxiety without adding skill&lt;br&gt;
Day 1: logistics and rest&lt;br&gt;
Boring and important.&lt;/p&gt;

&lt;p&gt;Test the setup&lt;br&gt;
Link, camera, microphone, editor, backup contact.&lt;br&gt;
One easy warm up&lt;br&gt;
A problem you can solve, for confidence rather than learning.&lt;br&gt;
Sleep&lt;br&gt;
The single highest return activity of the week.&lt;br&gt;
Plan the morning&lt;br&gt;
Food, travel or login time, and a buffer.&lt;br&gt;
Common questions&lt;br&gt;
Short answers.&lt;/p&gt;

&lt;p&gt;Can I prepare in one week?&lt;br&gt;
How do I find the weak round?&lt;br&gt;
Cram the night before?&lt;br&gt;
How many problems a day?&lt;br&gt;
Depth in one place beats panic everywhere&lt;br&gt;
Every rushed week I have done badly was a week spread thin. The one that worked looked lazier on paper and went deeper where it counted.&lt;/p&gt;

&lt;p&gt;Do the audit tonight. Whatever you avoid scheduling is the thing to spend the week on.&lt;/p&gt;

&lt;p&gt;Written on a Sunday, calmly for once&lt;/p&gt;

&lt;p&gt;What is your weakest round?&lt;/p&gt;

&lt;p&gt;Be honest, that is the whole method.&lt;br&gt;
Some third-party reviews of these tools are published by competing products, so verify prices on official sites before buying.&lt;/p&gt;

</description>
      <category>career</category>
      <category>interview</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
