Discern and perform an operation on a list
You could use Object.keys and Array#some to determine if any key in an object fits your criteria:

found = Object.keys(operations).some((op) =&gt; arrayses.letteros.indexOf(op) !== -1);


In general, you can use Object.keys and array iteration methods (forEach, map, reduce, some, every, etc.) to replace for..in loops.