0

Trip Planner Java Script cannot understand

29th Dec 2020, 9:34 AM
B K JAYAVIGHNESH
2 Antworten
+ 1
B K JAYAVIGHNESH It is very easy, if you use the formula: time = distance/speed You just need to calulate time here. Tip: remember to convert the time from hours to minutes. Further, please use search before asking a question https://www.sololearn.com/Discuss/2645103/?ref=app
29th Dec 2020, 9:40 AM
Art1mis
+ 1
function main() { var distance = parseInt(readLine(), 10); //your code goes here const speed = 40 var time = (distance/speed)*60 console.log(time) }
12th Feb 2021, 8:06 PM
Mohamed Salim
Mohamed Salim - avatar