Skip to content

Results for “php”

2 prompts

Add documentation to the code below. Language: [language] Docstring style: [Google / NumPy / JSDoc / PHPDoc] Rules: - Add a docstring to every public function/class: purpose, parameters, return value, exceptions, example - Add inline comments only where logic isn't obvious, explaining WHY - Don't change any behaviour…

Copilot
Coding & Development

Add clear comments and docstrings

Document existing code with helpful docstrings and comments that explain the why, not just the what.

0

Write unit tests for the function below. Language: [language] Testing framework: [e.g. Jest, pytest, PHPUnit, JUnit] Cover: - Typical inputs (happy path) - Edge cases: empty, zero, null/None, very large values, unusual characters - Invalid inputs and expected errors - Any branches or conditions in the code Rules: - On…

Copilot
Coding & Development

Write unit tests for any function

Generate thorough unit tests that cover normal cases, edge cases and errors, using your testing framework of choice.

0