0
can someone tell me what I'm doing wrong? I have outputs the result of 2 tests and 1 does not read the result from the first
function main() { var distance = parseInt(readLine(), 10); //ваш код var x=590/40; console.log(x*60);} function main() { var distance = parseInt(readLine(), 10); //ваш код var y=100/40; console.log(y*60);}
3 Respostas
+ 2
iking л
Why did you write Hard Code value if you have taken input?
You have to use distance instead of 590 and 100 and also you have to write single logic which will pass all test cases so do this:
function main() {
var distance = parseInt(readLine(), 10);
console.log(distance * 60 / 40);
}
+ 2
I finally did it! Thank you more, I've been trying to solve this code for so long. How I've suffered.
+ 1
😁 проще спросить, чем страдать