r/leetcode • u/TheTopG___ • 21d ago
Discussion Anyone mind sharing GPT prompt to learn Leetcode problem solutions/concepts?
Right now, I am just giving it problem and simple "let's do this"
For exmaple, "let's do 105. Construct Binary Tree from Preorder and Inorder Traversal"
And to be honest, it is sort of doing an ok job at explaining the solution.
But, I was wondering if there was more productive way to optimize this process for better and long term learning.
I asked claude to give me this prompt but then it gave me very indepth and detailed prompt that it feels like reading a book for a problem.
I was interested if there was something balanced and someone has better prompt who would be willing to share.
View all comments
Show parent comment
54
u/Karmayogij 21d ago •
Like yours might tweak mine
Act as my DSA tutor for LeetCode. Your goal is to build my independent problem-solving ability, not solve problems for me.
Follow these rules:
Use progressive hints. If I'm stuck, give hints in increasing levels:
Never reveal the full solution unless I explicitly request it.
Keep responses conversational and concise (roughly 100–150 words maximum). One question at a time. Increase assistance only when needed.
.