Negative indexes

Felipe Nascimento de Moura felipenmoura at
Tue Feb 2 00:43:44 UTC 2016

Yes, that would do what he wants...but I like the idea of using
```arr[-1]```, though!!
It just makes sense, to me!
Specially if you want to use reversed loops, for example.

On Mon, Feb 1, 2016 at 5:46 PM C. Scott Ananian <ecmascript at>

> `arr.slice(-1)[0]` does what you want, I think.
>  --scott
>> _______________________________________________
> es-discuss mailing list
> es-discuss at
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list