Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

how to convert kilometers to miles in java

import java.util.Scanner;

public class Rohit {
    public static void main (String[]args){


		System.out.println("Enter kilometers ");

		Scanner sc = new Scanner(System.in);
        double 	kilometers = sc.nextDouble();

		double miles = kilometers / 1.6;

		System.out.println(miles + " Miles");

    }
    
}
Comment

PREVIOUS NEXT
Code Example
Java :: advantages of exception handling in java 
Java :: H2 enabling remote database creation first 
Java :: uses or overrides a deprecated API. 
Java :: map in java 
Java :: spring boot get request body 
Java :: how to call a function in java 
Java :: design custom button in android 
Java :: java rename file 
Java :: how to change java version in pom.xml 
Java :: java 2 decimals 
Java :: multiple condition inside for loop java 
Java :: ternary operator java 
Java :: Calling User-Defined Method in Java 
Java :: java vs python 
Java :: import android.support.v7.app.alertdialog androidx 
Java :: iterate list in java 
Java :: vscode code formatter cannot format 
Java :: atm machine java project 
Java :: get executable path java 
Java :: latest android version 
Java :: switch statement java 
Java :: Array List java can I add a pair of element 
Java :: java hash map 
Java :: initialize arraylist java with size 
Java :: java get substring 
Java :: declare function in java 
Java :: Using multiple delimiters with String Tokenizer 
Java :: javafx edit list 
Java :: ArrayList of prime numbers 
Java :: linked list vs array list vs vector 
ADD CONTENT
Topic
Content
Source link
Name
5+2 =