+ 1

trip planner

Hi people, i cannot pass this exercise, can you please help to continue with javascript? You need to plan a road trip. You are traveling at an average speed of 40 miles an hour. Given a distance in miles as input (the code to take input is already present), output to the console the time it will take you to cover it in minutes. Sample Input: 150 Sample Output: 225 https://code.sololearn.com/ca22A476a8a1/#node

6th Apr 2021, 3:44 PM
Matias Nicolas Elia
Matias Nicolas Elia - avatar
6 Answers
+ 1
Don't assume distance as 150, that's just an example. Distance is given by input on line 3. Only numbers in your code should be 40 (miles) and 60 (minutes).
6th Apr 2021, 3:59 PM
Benjamin JĂŒrgens
Benjamin JĂŒrgens - avatar
+ 1
you should substitute the "distance" variable instead of the direct distance value. the test program will automatically substitute its own values
6th Apr 2021, 5:30 PM
Yaroslav Vernigora
Yaroslav Vernigora - avatar
0
I tried distance/speed 150 / 40 but says no outputs,
6th Apr 2021, 3:54 PM
Matias Nicolas Elia
Matias Nicolas Elia - avatar
0
test 1 has been solved. but now with test 2 if i change the output says that test 1 is wrong. how is it work? it is the first time i use this to practise.
6th Apr 2021, 4:15 PM
Matias Nicolas Elia
Matias Nicolas Elia - avatar
0
cool
30th Nov 2024, 10:37 AM
Gastino Gangster
Gastino Gangster - avatar
0
Planning your next trip doesn’t have to be a complicated, time-consuming process anymore. With best ai trip planner https://easytrip.ai/ you have a powerful tool that takes the hassle out of organizing your travel. Whether you’re looking to compare flights, explore train schedules, or find the best driving routes, this platform uses AI to create customized travel plans that fit your preferences perfectly. What makes EasyTrip.ai stand out is its ability to balance speed, cost, and convenience. Instead of juggling multiple websites and options, you get everything in one place, saving you time and effort. It’s the ideal solution for travelers who want to focus on the journey and not get lost in the details of planning. Try EasyTrip.ai and make every trip stress-free!
30th Nov 2024, 10:40 AM
Gastino Gangster
Gastino Gangster - avatar