Skip to content

Programming Prompts

Use these prompts to get small, runnable programs from an AI assistant β€” code that reads input, does one job clearly, and prints a result you can check.

  • You need a quick command-line script for a well-defined task.
  • You want standard-library-first code with minimal setup.
  • You want example input and output alongside the code so you can verify it.
Prompt What it does
Generate Python Code Prompt template for generating practical Python code that reads from stdin and outputs to stdout.
  1. Open a prompt and copy the text block.
  2. Replace every placeholder in angle brackets, such as <TOPIC> or <TASK>.
  3. Describe the input, the expected output and an example after the prompt.
  4. Run and test the generated code yourself; never deploy code you have not read and executed.