Prompt to learn a new programming language fast
Learn a new programming language through the one you already know, with side-by-side examples, the habits to unlearn and a small first project.
- Category
- Learning
- Tags
- StudyingExplaining
- Added
- Added
Fill in the prompt
The prompt below changes as you type, and Copy prompt copies it filled in. What you type stays in this browser. Leave a box empty to fill it in after you paste.
The prompt
I know {{known_language}} well and I'm learning {{new_language}}. Teach me through what I already know.
1. The mental model: how {{new_language}} thinks differently from {{known_language}}, in five bullet points.
2. Side by side: short examples of the same task in both languages. Cover variables and types, functions, error handling, collections, async or concurrency, modules and packages, and testing.
3. Traps: habits from {{known_language}} that produce bad or broken {{new_language}} code, with an example of each.
4. Tooling: the standard way to create a project, add a dependency, format, lint, test and build.
5. Idioms: five things an experienced {{new_language}} developer does that a newcomer doesn't.
6. A first project I could finish in an evening that uses most of the above.
Use the current stable version of {{new_language}}, and say which version that is.
Replace each {{highlighted part}} with your own text before you send it.
How to use it
Put the language you're fluent in into {{known_language}} and the one you're learning into {{new_language}}. Each appears several times in the prompt, so every section stays a comparison rather than a generic tutorial.
The comparison works best between languages that share some ground, such as C# and Kotlin or JavaScript and Go. It still helps between distant ones, and there the traps section matters most.
Example: "Python" for {{known_language}} and "Rust" for {{new_language}}.
Check the version the model names against the language's official site, because tooling moves fast and a model's knowledge stops at its training date. Type out the side-by-side examples and run them. Reading them gives you the shape, but running them is what tells you whether it stuck.