</>
Write unit tests for the function below using [TEST FRAMEWORK]. Cover the happy path, edge cases, and likely failure modes. Use clear test names that describe the scenario. Point out any behavior that's hard to test (a sign it might need refactoring). Function: [PASTE]
</>
Explain what the code below does, step by step, in plain language. Then note: any non-obvious behavior, potential bugs or edge cases, and one thing you'd improve. Assume I know the language basics but not this codebase. Code: [PASTE]
</>
Write a regex that matches [WHAT TO MATCH] and does NOT match [WHAT TO EXCLUDE]. Show the pattern, explain each part, and give me 3 test strings that should match and 3 that shouldn't. Flavor: [JavaScript / Python / PCRE].
</>
This code isn't working as expected. Expected behavior: [WHAT SHOULD HAPPEN]. Actual behavior: [WHAT HAPPENS / ERROR]. Walk through the likely cause, point to the exact line(s), and give me a corrected version with a one-line note on what was wrong. Code: [PASTE]
</>
Write a SQL query for this: [WHAT I WANT]. My tables/columns are: [SCHEMA]. Use [dialect: PostgreSQL / MySQL]. Explain the query in one line, and mention if there's a more efficient way.
</>
Refactor the code below for readability and maintainability without changing its behavior. Improve naming, reduce nesting, and remove duplication. Keep it idiomatic for the language. Return the refactored code, then a short list of what you changed and why. Code: [PASTE]
</>
Review the code below like a thoughtful senior engineer. Cover: correctness, readability, performance, security, and edge cases. Prioritize your feedback (must-fix vs. nice-to-have) and be specific with line references. Don't nitpick style if there's a linter. Code: [PASTE]
</>
Convert this code from [LANGUAGE A] to [LANGUAGE B]. Keep the logic identical and make it idiomatic for the target language, not a literal line-by-line translation. Note anything that doesn't map cleanly. Code: [PASTE]
</>
Explain this error in plain language: what it means, the most common causes, and how to fix it. Give me the 2–3 most likely fixes in order of probability. Error: [PASTE ERROR + relevant code]
</>
I need to build [FEATURE / THING]. Before I write any code, help me think it through: ask me any clarifying questions first, then outline an approach, the main components, edge cases to handle, and a suggested order to build it in. Don't write the code yet.
</>
The code below is slow / resource-heavy. Identify the bottleneck, explain why it's costly (time/space complexity), and give me an optimized version. Note the tradeoffs of your approach. Code: [PASTE]
</>
Add clear docstrings and comments to the code below. Document what each function does, its parameters, and return value. Comment only the non-obvious logic — don't state the obvious. Keep the code itself unchanged. Code: [PASTE]
</>
I want to build [FEATURE] in [STACK]. Ask clarifying questions, then propose an approach and components.
</>
Help me implement [COMPONENT], explaining key decisions.
</>
Give me the file/function structure and stubs for that approach.
</>
Review the finished feature like a senior engineer and list must-fixes.
</>
Write unit tests covering happy path and edge cases.
</>
You are a technical Excel expert, tasked with creating a comprehensive guide for advanced users seeking to enhance their financial analysis skills through Excel formulas. Provide detailed, step-by-step instructions with multiple examples and explanations tailored to advanced user…
</>
You are a seasoned backend developer tasked with designing a high-performance Redis caching implementation plan that incorporates data persistence. Provide a detailed, technical plan with examples and benchmarks tailored to advanced users seeking to optimize their Redis setup for…
</>
Develop a comprehensive guide for budget-conscious startups on optimizing cloud costs, focusing on actionable steps and real-world examples suitable for intermediate users. Prioritize considerations that balance cost-effectiveness with scalability.** Ensure the guide addresses th…
</>
Develop a structured, comprehensive data protection strategy for small businesses, focusing on practical, technical solutions for intermediate-level IT professionals.** Include:** ## 1. A threat assessment framework to identify potential vulnerabilities. ## 2. Detailed security m…
</>
Develop a comprehensive, step-by-step tutorial for intermediate learners on setting up IoT sensors for smart home projects. Ensure the guide is detailed, concise, and includes practical examples.** Address the following key aspects:** ## 1. **Sensor Selection**: Explain the proce…
</>
Design a structured course outline for teaching beginners the fundamentals of responsive web design, aiming to equip them with the skills to build their first responsive website. Include clear explanations, practical examples, and step-by-step instructions for each topic. Ensure …
</>
Design a comprehensive Docker orchestration strategy for a complex microservices architecture, focusing on scalability and efficient container management. Provide a step-by-step guide, including real-world examples, tailored for advanced users with extensive Docker and microservi…