0
Can someone please help me with the answer to the 44th code project, store manager in the JavaScript lesson?
Ive bee trying for a while now. I really need help. The answer should be in JS4 please.
5 Respostas
+ 1
Moses Uga
function main() {
var increase = parseInt(readLine(), 10);
var prices = [98.99, 15.2, 20, 1026];
for (i=0; i<4; i++){
prices[i]+=increase
}
console.log(prices)
}
+ 1
Abhay Thank u
0
Can you shows us the code you have written so far ?
0
Abhay here:
function main() {
var increase = parseInt(readLine(), 10);
var prices = [98.99, 15.2, 20, 1026];
for (i=0; i<4; i++){
y = prices[i] + increase
arr = [y]
console.log(arr)
}
}
0
for (x = 0; x < prices.length; x++) {
prices[x] += increase;
}
console.log(prices);