Forum Discussion
moanawatt
Oct 14, 2022Copper Contributor
I want to random number formula for Game 24
Game 24 is a kind of math game. Players are given 4 numbers which range from 1 to 9 (it can't be 0, but can be 10,20, etc.) and must use addition, subtraction, multiplication or division to get a val...
dscheikey
Oct 14, 2022Bronze Contributor
Hi! One possibility for your 4 random numbers is the following function:
=CHOOSE({1,2,3,4},RANDBETWEEN(1,10),RANDBETWEEN(1,10),RANDBETWEEN(1,10),RANDBETWEEN(1,10))
Instead of writing RANDBETWEEN() 4 times, you can also use the following function:
=MAKEARRAY(1,4,LAMBDA(a,b,RANDBETWEEN(1,10)))
Brand new - and therefore possibly not yet available for you:
=RANDARRAY(1,4,1,10,TRUE)
I hope I was able to help.