forEach loopp exmaple::: when we pass the function parameter this paramter can beutimartically work when we us this forEach fyunction.

PHOTO EMBED

Fri Mar 17 2023 19:14:37 GMT+0000 (Coordinated Universal Time)

Saved by @bhushan03

  let arr=[
    {first:"bhushan",age:2},
     {first:"shan",age:22},
      {first:"bhu",age:29},
      
    ];
    
    //taask ::to print first elemtn of object
    
    
    arr.forEach(function(arr){
        console.log(arr.first);
        
    }
        )
content_copyCOPY

https://www.programiz.com/javascript/online-compiler/