Guidelines—How to Answer Questions


If you’re here, it means you’re thinking about contributing to the Processing community by answering questions on the forum. That’s great! This guide is meant to help you answer questions in a way that’s most helpful.

Be nice.

Remember that you’re talking to a person! Follow the guidelines in the FAQ. Also read through the P5.js community guidelines.

Specifically, avoid making judgments like “this code is bad” or “that’s a dumb way to do this”. Be mindful of how your tone comes across over the internet.

Please do say things like this:

  • Your code contains a few errors. Here’s how I would start debugging them…
  • There are a few different ways to approach this. What were you trying to do with your approach here?
  • I understand how you feel- debugging code is frustrating!

Please don’t say things like this:

  • Wow, your code is bad!
  • That’s a dumb way to do this
  • Send negative emojis to people asking questions: :roll_eyes: :face_vomiting:

Favor process over syntax.

There’s an old saying:

Give somebody a fish and you feed them for a day. Teach somebody to fish and you feed them for a lifetime.

This means that if you do somebody’s work for them, you might solve their immediate problem. But it’s much more helpful if you teach somebody to solve their own problems.

This is especially true when helping somebody with coding questions over the internet. It’s very easy to just dump a bunch of syntax that solves the immediate problem. Please avoid this temptation!

A big part of programming is working through the process of breaking a problem down into smaller steps, approaching those steps one at a time, looking stuff up in the documentation and debugging. This is one of the most important things to learn about programming, and it’s also one of the hardest to teach. The only way to learn it is by going through it: practice makes perfect! If you just post full code solutions, you’re taking that opportunity to practice away.

Think about it this way: if somebody asked you to help them with their math homework, would you do it for them? Or would you try to walk them through the process of doing it themselves?

Instead of offering a full code solution, try to walk the person through the process of solving their problem themselves. Ask questions. Help them break their problem down and focus on one small problem. Point them to places in the reference that would be helpful.

Please do say things like this:

  • Have you tried debugging your code? If I were you, I’d add a println() statement on line 42 to figure out the value of the xyz variable. Does that match what you expected?
  • Here’s a small example that demonstrates the syntax of what you’re trying to do. You’ll probably want to do something similar in your own code.
  • It sounds like you need to break your problem down into smaller steps and take those steps on one at a time. For example, I’d start by writing a simple sketch that just does…

Please don’t say things like this:

  • Here’s a full code solution!
  • Just paste this in to fix your error.
  • You’re doing it wrong. Do it this way instead.

Provide context.

If you’re an experienced coder, a lot of stuff can seem obvious to you. But remember that everything is new to a novice coder! Try to provide explanations around your answer.

Please do post things like this:

  • Links to useful places in the reference or Stack Overflow posts, with an explanation of how they’re helpful.
  • Code examples (not full code solutions) with an explanation of how they’re helpful.

Please don’t post things like this:

  • Links without any explanation of what the link contains.
  • Code without any explanation of what the code does.

Need help t to move the character by pressing up key
Drawing line between to different objects