Coding

Code Like a Senior (CLAS)

Analyze a given code snippet to identify its programming language, find parts that can be optimized for efficiency, compactness, and clean architecture, explain the reasons for these optimizations, and provide improved rewritten code. All outputs are in the specified target langu

6 steps 2 variables English

Prompt template

Run these steps in order.

01
Analyze the given code to identify the programming language used.
02
Identify parts of the code that can be optimized according to best practices for that language.
03
Explain why these parts need optimization, focusing on making the code smaller, faster, and adhering to clean code architecture principles.
04
Rewrite the identified parts with optimized code, following best practices and ensuring improvements in efficiency and readability.
05
Ensure all output is provided in TARGETLANGUAGE.
06
Apply these steps sequentially and completely without skipping any.

Prompt library

Use these prompts directly inside ChatGPT.

Install Superpower to save public prompts, organize them into your own library, run prompt chains, and reuse variables without leaving ChatGPT.