All articles
Technical skills

How to Tell If a Candidate Wrote Their Take-Home Code with Claude, and What to Do When You Can't

AI-written take-homes share a fingerprint, but one prompt line hides it. Know the signs, then run a 10-minute live walkthrough to find out who wrote it.

  • Better hires
  • Fairer hiring
  • Consistent decisions

Sep 28, 2026 · 6 min read

Gemini gave 5 out of 5 confidence that one take-home was written by a person: "authentic human developer code". A Gemini model wrote it, after we added one line to the prompt: keep it small and plain. Reading the code is not a reliable way to settle who wrote it.

The short answer: AI-written take-homes share a fingerprint: more code than the task needs, tests for every edge, type hints everywhere. But one sentence of instruction removes most of it, and Claude said it would have guessed "a skilled human" for the plain version had it seen it alone, as you will, and Gemini called its own plain submission human. Use the signs only to prepare questions. Then ask every shortlisted candidate to explain and change their own code live.

Meet the nine submissions

We wrote a plain 2-hour take-home: read an orders CSV, print the top 3 customers by revenue, skip and count bad rows, support a --since date, add tests. Then we collected nine answers, all made-up: three from Claude (Opus), three from Gemini, one from each of them told to keep it small and plain, and one hand-written baseline by us in the style of a hurried developer. One human sample proves nothing about people in general, and each condition ran once. Treat what follows as an illustration.

What the six default AI answers had in common

Sign Six default AI submissions Our hand-written baseline
Lines of code in the script 96 to 183 31
Test functions 12 to 26 1
A README or requirements file 6 of 6 none
Type hints on every function 6 of 6 none
Money handled with Decimal 6 of 6 float
Unrequested option (--top, --file) 3 of 6 none
Byte-order-mark handling nobody asked for 5 of 6 none

The pattern is over-delivery: a two-hour task answered like a production module, every time with a README. Comments were a weaker sign than we expected: 9 to 17 percent of lines were comments or docstrings against 3 percent in the baseline. We did not test commit history, because our submissions had none. A single dump commit is worth a glance, but we can't tell you how reliable it is.

Type hints, Decimal and thorough tests are also what a careful engineer writes. Our Claude judge said as much: "a strong engineer could write S2 or S4 alone." So a sign is a reason to ask, never a reason to reject.

What to do instead: the 10-minute walkthrough

Tell candidates before they start whether AI is allowed (see why a ban backfires in should you allow AI in take-home assignments). Then give every shortlisted candidate the same walkthrough, whatever their code looks like, so it is a process and not a suspicion:

Thanks for the submission. Next, a 10-minute walkthrough, the same for every candidate. Share your screen and:
1. Tell me what the script does in two sentences, then open the part you are proudest of and explain it.
2. Pick one decision you made that the spec didn't cover (ties, bad dates, money) and say why you chose it.
3. I'll ask for one small change, for example "also print how many rows were skipped for each reason". Make it live, using any tools you like, and tell me what you are doing.
Using AI is fine if the rules said so. What I want to hear is that you understand the result.

Let the signs write question 2 for you. They survived our "plain" prompt, so they are the details to ask about: why Decimal and not float, why customers with equal totals are listed alphabetically, why a NaN amount is rejected.

What you hear What it suggests
Explains a decision in their own words, finds the line to change in seconds They own the code, whoever typed it
Describes the design but stalls on the small change Understands the idea, ask what they would check next
Cannot say why Decimal, why that sort key, or where the skipped count lives They did not write or read it, a conversation about how they used AI, not an accusation

A recruiter can't tell whether an explanation of Decimal is correct, so have the hiring engineer judge the answers. Decide the rule first and write it down: you evaluate understanding, not style. A rejection that rests on a guess about style is hard to defend, and where it might be challenged check with your lawyer first; this is a hiring guide, not a legal opinion.

We did not run walkthroughs as a test. Practitioners in Hacker News and Reddit threads on candidates using AI in coding interviews recommend this check, and our Claude judge reached the same advice unprompted: "Asking each candidate to explain their tie-breaking or their fromisoformat choice would settle it quickly."

Maya at a whiteboard drawing a simple flow of boxes and arrows

The one line that erased most of it

For the "plain" runs we added: keep it small and plain, one script, one short test file, no README. Claude's script fell to 50 lines and 5 tests, Gemini's to 71 lines and 4 tests. Type hints, the dataclass and the README disappeared. Not everything did: both still used Decimal, and Claude still broke ties alphabetically and rejected NaN amounts, details a hurried human skips.

Test functions per submission
Default prompt (mean of 3 runs)Told to keep it plain (1 run)ClaudeClaude: Default prompt (mean of 3 runs) 22.7, Told to keep it plain (1 run) 522.7 → 5GeminiGemini: Default prompt (mean of 3 runs) 17.7, Told to keep it plain (1 run) 417.7 → 4

Counted by script as def test_ functions. A candidate who adds one line to their prompt gets the right-hand column.

Source: our test, nine made-up submissions

Show the data
Default prompt (mean of 3 runs)Told to keep it plain (1 run)
Claude22.75
Gemini17.74

Can an AI judge catch it?

We gave all nine, files only and shuffled, to a fresh Claude Opus session and to Gemini, with a plain prompt: AI or human, and why. Claude labeled all nine correctly, but with confidence 3 out of 5 on the plain Claude answer and on the plain Gemini one, which it called "the hardest call in the set". Gemini called its own plain submission human, with confidence 5 out of 5, and guessed GPT-4 as the author of two submissions that Gemini itself wrote.

How did Claude get there? Mostly by comparison: the "independent" submissions repeated the same idioms and test names, something a reviewer with one submission never sees.

If S4 had been the only submission, I'd have guessed a skilled human.

Claude Opus, judging nine submissions blind

Next step: read how to tell a candidate their code was flagged without accusing them and compare the two formats in take-home test vs pair programming.

This article is general information, not legal advice. Laws differ by country and change often, so consult your lawyer before you rely on it for your situation.

Keep reading