Rubber Duck Debugging Sabotage

Par 3
Question 74beginnerSheet 1750822302

Deep Breath

A programmer's rubber duck achieved sentience and now provides actual debugging advice. It has developed strong opinions about code quality and isn't afraid to share them. The duck occasionally quacks disapprovingly at poorly written functions and demands proper variable naming conventions. Your task: Debug with a judgmental rubber duck who offers solid advice but also passive-aggressively quacks every time you name a variable x or y.

Why You're Doing This

This tests conditional response generation, personality modeling, and providing contextual advice based on input parameters. You're building a system that adapts its communication style and content based on both the problem and the advisor's personality.

Take the W

  • Provides debugging advice appropriate to duck personality
  • Adjusts tone and helpfulness based on code quality
  • Maintains duck character while giving useful technical guidance

Hard L

  • Ignores duck personality parameters
  • Provides inappropriate or harmful debugging advice
  • Breaks character or provides inconsistent responses

Edge Cases

  • Perfect code that doesn't need debugging
  • Problems that exceed duck's programming knowledge
  • Duck having existential crisis about rubber existence
Input Format:
Debugging session object with duck configuration and code analysis
Expected Output:
Duck response with debugging guidance and personality metadata
Example:
{"problem": "infinite_loop", "duck_type": "encouraging", "code_quality": "poor"} → {"advice": "Add loop counter, dear", "quacking": "gentle_disapproval", "encouragement": "You can do better!"}
Hints
  • 💡 Duck personalities: encouraging, sarcastic, perfectionist, zen_master
  • 💡 Code quality affects duck's emotional state and advice tone
  • 💡 Balance helpful debugging with duck character consistency