vendredi 7 février 2020

get non repeating random numbers from an array

I'm making a quiz. I try to find a way to generate non repeating random numbers from an array. How can help me? This is what I got:

questions = ["Q1", "Q2", "Q3", "Q4", "Q5", "Q6", "Q7"] var randoms001 = Math.floor(Math.random() * questions.length);




Aucun commentaire:

Enregistrer un commentaire