0
I was made a Simple Game with Javascript but...
This is game java secript code is to lengthy, any body can tell me how can we write code shortly.?? Thanks in Lenghty Code bits : https://code.sololearn.com/WM2ozl4S6Njn/?ref=app
4 Antworten
+ 1
Sajid Ali
See here I have minimised JS code using loop and also you need to clear timeout after wins. Also I have changed box to box0 in html.
https://code.sololearn.com/W8I4yokuEYC8/?ref=app
+ 1
I Am AJ ! Thank you so much 🙏
0
Sajid Ali
As I see everything is same just variable name changed like box1, box2, box3, top1, top2, top3....so you can try loop and make variable dynamic.
0
I Am AJ ! Can you write ? How can we adjust variable in loop ?