DEV Community

Discussion on: 4 main differences between forEach() and map() you should know

Collapse
 
ibrahima92 profile image
Ibrahima Ndaw

Thanks, for your comment I intentionally use the same example for both map and forEach to just not confuse folks. But, if you read my final thought, you'll see that map is all about transforming data, and this example should be done with map.