Friday, 10 July 2015

Write a program to convert rupees to dollar. 60 rupees=1 dollar


  
 
import java.util.Scanner;

public class Program_1 {

    public static void main(String[] args) {

        int rupees;
        double dollar;

        Scanner scan = new Scanner(System.in);

        rupees = scan.nextInt();

        dollar = rupees / 60;

        System.out.println(rupees + " Rupees = " + dollar + " Dollar");

    }
}
  

No comments:

Post a Comment