+ 3

How can add counting in JavaScript

reverse counting

12th Jan 2017, 1:44 PM
AKSHAY🇼🇳
AKSHAY🇼🇳 - avatar
2 Answers
+ 9
var a = 5, b; while (a > 0) { b += a; a--; } (what exactly do you want??)
12th Jan 2017, 1:46 PM
Valen.H. ~
Valen.H. ~ - avatar
+ 4
var x=prompt("Enter the starting number"," "); var y=x; for(y=x; y>=0; y--){ document.write(x); }
12th Jan 2017, 3:12 PM
Prabhakar Dev
Prabhakar Dev - avatar