Number guessing game

I’m new to processing and have an homework assignment to make a number guessing game. I have no idea where to start and i cant find anything online. Can anyone help me?

1 Like

How would a number guessing game work? If you can plan out how you want something to work then you have a basis for writing computer code.


Hi and welcome

This is the basic structure of the code
You need to make random numbers say between 0-9

Int  play_guess
Int play_guess  = int(random(9)); //Random number generation

Then you need to use if and else and key pressed


Yeah, sorry, this is not how the forum works.

Please come up with a basic Sketch with setup() and draw() and ask specific questions.

  • Make a PLAN
  • write down the steps
  • what do you expect to see from the program on the screen?
  • Start to program the single steps that you’ve identified
  • Then ask specific questions like “how can I get a random number?”.

Warm regards,


1 Like