1 line of code: How to get every odd item of an Array
const oddItems = arr =&gt; arr.filter((_, i) =&gt; i &amp; 1 === 1);        Enter fullscreen mode   ...
Tags: javascript, webdev, performance, codequality