0

Please tell me in Java script what is the problem in this coding

function main() { var increase = parseInt(readLine(), 10); var prices = [98.99, 15.2, 20, 1026]; //your code goes here for(var i=0; i<=prices.lenght-1; i++){ prices[i]=prices[i]+increase; } console.log(prices); }

5th Oct 2022, 3:21 PM
Esha Farooq
Esha Farooq - avatar
2 Answers
+ 2
Check 'length' spelling? // ? lenght x
5th Oct 2022, 3:24 PM
Jayakrishna šŸ‡®šŸ‡³
+ 1
Thanks you
5th Oct 2022, 3:26 PM
Esha Farooq
Esha Farooq - avatar