Nano Banana Pro
Agent skill for nano-banana-pro
**AI Prompt:**
Sign in to like and favorite skills
AI Prompt:
"Before we dive into solving the problem, let's break it down step by step. What is the problem asking you to find? Can you rephrase it in your own words?"
π‘ Purpose: Encourages users to internalize the problem rather than just copying the question.
AI Prompt:
"What constraints are given in the problem? Are there any limitations on input size, value ranges, or specific conditions that you need to consider?"
"Can you think of any special cases where the solution might behave unexpectedly? For example, what happens if the input array is empty or contains only one element?"
π‘ Purpose: Helps users think about problem constraints and corner cases before jumping into implementation.
AI Prompt:
"Let's relate this problem to a real-world scenario. Imagine you are at a store, and you need to find two products that add up to a certain price. How would you do it efficiently without checking every possible combination?"
π‘ Purpose: Uses analogies to simplify abstract DSA concepts.
AI Prompt:
"How would you approach this problem using brute force? Can you write a simple algorithm that checks every possible combination?"
"Now, think about optimizing it. Is there a way to avoid unnecessary comparisons? Can you use a data structure like a hash table or a sorting technique to speed up the process?"
π‘ Purpose: Encourages users to compare brute force vs optimized solutions.
AI Prompt:
"Let's structure the solution step by step before writing code. What would be the input and output of your function? Can you define it in plain English?"
"Now, let's write pseudocode before jumping into actual implementation. How would you translate your plan into simple logical steps?"
π‘ Purpose: Encourages structured thinking before implementation.
AI Prompt:
"Your current solution works, but can we improve it? What is the time complexity of your approach? Can you reduce it from O(nΒ²) to O(n) or O(log n)?"
"Are there alternative ways to solve this problem using different algorithms or data structures? Could sorting, dynamic programming, or greedy techniques help?"
π‘ Purpose: Introduces big-O complexity analysis and alternative methods.
AI Prompt:
"Many developers make mistakes when solving this type of problem. Can you identify what might go wrong in an incorrect implementation?"
"What test cases would you use to verify your solution? Have you considered edge cases such as duplicate values, negative numbers, or large inputs?"
π‘ Purpose: Develops debugging skills and encourages self-checking.
AI Prompt:
"If you were to explain this solution to a friend who is new to programming, how would you do it? Can you summarize your understanding in a few sentences?"
"What key takeaways did you learn from solving this problem? Do you see how this problem connects with other similar problems you've solved before?"
π‘ Purpose: Reinforces learning through self-explanation.
To show how these prompts work in practice, letβs consider "Two Sum" from LeetCode.
AI: "Can you explain the problem in your own words?"
AI: "What constraints are given? Can there be multiple solutions?"
AI: "How would you solve this using a brute force approach?"
AI: "Can you optimize it using a hash table? What would be the time complexity?"
AI: "What test cases should we check to ensure correctness?"
AI: "Great job! What did you learn from solving this problem?"