0
The Snail in the Well error :(
3 Respuestas
+ 6
//try this
for (;climb<depth;day++){
climb+=7-2
}
console.log (day)
+ 1
Simba Thanks -> This one also looking Cool -|
^
for (;climb<depth;climb+=7,day++){
climb -= 2;
0
With just one if statment , you dont need for loop at all :
if (depth%5<3){
var days=depth/5;
}else{
var days=(depth/5)+1;
}
console.log(parseInt(days));