1Using a FOR loop, write a function addNumber which adds the argument n to each
2number in the array arr and returns the updated arr:
3const addNumber=(arr, n)=>{
4 let arr1=[];
5 for(let i=0;i<Math.max(arr.length);i++){
6 arr1.push((arr[i]||0)+n)
7 }
8 return arr1;
9}
10console.log(addNumber([4, 5, 6], 7)); // expected log [11, 12, 13]
1let browsers = ['chrome', 'firefox', 'edge'];
2browsers.shift(); // "chrome"
3console.log(browsers); // ["firefox", "edge"]