The following seems like a very common practice in Javascript :
for (var i = array.Length - 1; i >= 0; i--) { /* do stuff here */ };
I never noticed this in other languages though ... Does it have any benefits over:
for (var i = 0; i < array.Length; i++) { /* do stuff here */ };
The only thing that comes to mind is the caching of the array length in the first one, which wouldn't be such a huge performance I'd guess. You could also have :
var top = array.Length;
for (var i = 0; i < top; i++) { /* do stuff here */ };
Giving you the same benefit
of caching, but might be a bit less performant
if you are minimizing your code (shaving maybe 8 characters when minifying the script)