0
Trying to figure out how to grab a random array then set interval by 1 seconds
Const myArray = ['January', 'February', 'March']; https://code.sololearn.com/WZ80NlPYzDse/?ref=app
8 Respuestas
+ 3
Yes question is clear but where did you try? Show us your code.
+ 2
Please first Try to do by yourself. People are not here to write your program. We are also learning here.
+ 2
Check this. Here setInterval function is given. You can take help of this.
https://www.w3schools.com/jsref/met_win_setinterval.asp
+ 2
If you freeze the value, there is no random each interval
https://code.sololearn.com/Wtlv6Dgr5i6l/?ref=app
You need to random each time the function is called, like this :
https://code.sololearn.com/W4CPu89KAWm3/?ref=app
+ 1
Then what problem you are facing? Share that.
0
I did
0
I corrected the question. Is that clear
0
I put it in there, I got the random array part. Trying to figure out how to setInterval function by 1 second