+ 3

Pls I need help with code coach : Trip planner

28th Dec 2020, 5:12 PM
Sumaya
Sumaya - avatar
5 odpowiedzi
+ 2
this is node.js function main() { var distance = parseInt(readLine()); x = (distance/40)*60 console.log(x); }
28th Dec 2020, 5:15 PM
Nilla
+ 2
Oh really i didnt know🤦‍♀️
28th Dec 2020, 5:18 PM
Nilla
+ 1
and this is java import java.util.*; public class TripPlanner { public static void main(String[] args){ Part1(); Part2(); Part3(); Part4(); } public static void Part1(){ Scanner input=new Scanner(System.in); System.out.println("Welcome!"); System.out.println("What is your name?"); String name=input.next(); //input name. System.out.println("Nice to meet you "+name+", Where are you Travelling?"); String place=input.next(); System.out.println("Great "+place+" sounds like a great trip!"); } public static void Part2(){ Scanner input=new Scanner(System.in); System.out.println("How many days are you going to spend travelling?"); int days=input.nextInt(); System.out.println("How much money, in USD, are you planning to spend on your trip?"); int money=input.nextInt(); System.out.println("What is the currency symbols favourite travel destination?"); String currency=input.next(); System.out.printl
28th Dec 2020, 5:16 PM
Nilla
+ 1
Wow! Thanks ☺️
28th Dec 2020, 5:16 PM
Sumaya
Sumaya - avatar
+ 1
function main() var distance = parseInt(readLine(40 miles), 10); console.log("3.75*60=255!");
28th Dec 2020, 5:18 PM
Sumaya
Sumaya - avatar