<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>JavaScript reverse array while loop</title>
</head>
<body>
<pre> <!-- Use pre element for work document.writeln() method -->
<script>
var arr = [10, 20, 30, 40, 50, 60, 70, 80, 90, 100];
number = arr.length;
while (number--) {
document.writeln("Value of arr[" + number + "] : " + arr[number]);
}
document.writeln("End of Loop.");
</script>
</pre>
</body>
</html>