home/roleplay/improve-the-following-code

Improve the following code

GPTClaudeGemini··722 copies·updated 2026-07-13
improve-the-following-code.prompt
Improve the following code

```
${selectedText}
```

Please suggest improvements for:
1. Code readability and maintainability
2. Performance optimization
3. Best practices and patterns
4. Error handling and edge cases

Provide the improved code along with explanations for each enhancement.

fill the variables

This prompt has 1 variable. Pro fills them into a ready-to-paste prompt for you — no manual find-and-replace.

{selectedText}
Unlock with Pro →

when to use it

Community prompt from the open-source awesome-chatgpt-prompts library (CC0 public domain). A proven "Improve the following code" starting point — swap in your own specifics and constraints. Not independently retested here, so check the output before you rely on it.

tags

roleplaycommunitygeneral

source

awesome-chatgpt-prompts · CC0 1.0 (public domain)