WORKED EXAMPLE
Sample output
Sample input
Python 3.12: def mean(xs): return sum(xs) / len(xs)
Sample output
Trigger: []. Impact: ZeroDivisionError. Fix: Raise a clear ValueError for empty input and handle it at the call site.
Verify with an empty list, one item and negative numbers.
Raw prompt
Review this code for security, correctness and maintainability: {code}. Language/version: {environment}. For each finding give the trigger, impact and a small proposed fix. Rank findings by severity. Do not claim tests were run unless they were.How to use this prompt
Copy the prompt, substitute your own input and paste it into your tool. Check the result against your goal.