I Haz Codes

Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Menu
Brain training

A simple “brain training” game will ask the user a random maths question. You need to write a simple game which will do the following –

  • Pick two random numbers.
  • Pick, at random, either addition, subtraction or multiplication.
  • Display the calculation to the user.
  • Ask them for their answer.
  • Check their answer and tell them if they are correct or not.

 

hint – pick a random number between 1 and 3. If it is 1, then do addition, if 2 then do subtraction etc.

Comments are closed.

Information