Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

ForEach

let data = ["A", "B", "C", "D"];
function process(element)
{
    console.log(element);
}
// With named Function
data.forEach(process);

// With Lambda/anonymous Function
data.forEach((element) => console.log(element));
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #ForEach
ADD COMMENT
Topic
Name
9+8 =