crop_rotate
Run
<!DOCTYPE html> <html> <body> <h2>JavaScript Array.find()</h2> <p id="demo"></p> <script> const numbers = [4, 9, 16, 25, 29]; let first = numbers.find(myFunction); document.write("First number over 18 is " + first); function myFunction(value, index, array) { return value > 18; } </script> </body> </html>
PCFET0NUWVBFIGh0bWw+DQo8aHRtbD4NCjxib2R5Pg0KDQo8aDI+SmF2YVNjcmlwdCBBcnJheS5maW5kKCk8L2gyPg0KPHAgaWQ9ImRlbW8iPjwvcD4NCg0KPHNjcmlwdD4NCmNvbnN0IG51bWJlcnMgPSBbNCwgOSwgMTYsIDI1LCAyOV07DQpsZXQgZmlyc3QgPSBudW1iZXJzLmZpbmQobXlGdW5jdGlvbik7DQoNCmRvY3VtZW50LndyaXRlKCJGaXJzdCBudW1iZXIgb3ZlciAxOCBpcyAiICsgZmlyc3QpOw0KZnVuY3Rpb24gbXlGdW5jdGlvbih2YWx1ZSwgaW5kZXgsIGFycmF5KSB7DQogIHJldHVybiB2YWx1ZSA+IDE4Ow0KfQ0KPC9zY3JpcHQ+DQoNCjwvYm9keT4NCjwvaHRtbD4=