CCARF Practice Question

Paper 5 · Question 25

D4 Prompt Engineering & Structured Output · Paper 5

[Scenario: Code Generation with Claude Code] You asked Claude Code to implement a function that transforms API responses into an internal normalized format. After two iterations, the output structure still doesn’t match expectations—some fields are nested differently and timestamps are formatted incorrectly. You described requirements in prose, but Claude interprets them differently each time. Which approach is most effective for the next iteration?

Show answer & explanations

Correct answer: B

Related Prompt Engineering & Structured Output questions

Paper 5 Q14[Scenario: Claude Code for Continuous Integration] Your code review component is iterative: Claude analyzes the changed file, then may reque…Paper 5 Q16[Scenario: Claude Code for Continuous Integration] Your automated reviews find real issues, but developers report the feedback is not action…Paper 5 Q18[Scenario: Claude Code for Continuous Integration] Your automated review analyzes comments and docstrings. The current prompt instructs Clau…Paper 5 Q19[Scenario: Claude Code for Continuous Integration] Your automated review generates test-case suggestions for each PR. Reviewing a PR that ad…Paper 5 Q20[Scenario: Claude Code for Continuous Integration] After an initial automated review identifies 12 findings, a developer pushes new commits …

More: Paper 5 · All practice questions