0
How to produce random sets of 2 or 3 numbers in JS or JQ ? Or is there any other way ?(All the numbers must lie between 1 and 6)
I want to make a game like this one - There are six buttons on a lock. Pressing a button will change the buttons surrounding it (but not the one you pressed) from red to green or vice-versa. The starting pattern of lights is random. Make all the buttons green.
4 Respuestas
+ 4
I hope it gives you an idea
https://code.sololearn.com/WgpRH2T2PC0A/?ref=app
+ 1
Sadness ah ! Thanks that was easier than I thought, now I can start my new project.
0
𝐊𝐢𝐢𝐛𝐨 𝐆𝐡𝐚𝐲𝐚𝐥 the thing is I have not typed anything related to this code I just want random number sets to make my game work(which is not existing, yet)
I want some code to return such values :
[2,5,6]
[3,6]
[1,4,5] (all the numbers must be different)
etc.
It would be an easier task for me if it is written in JS or java.