Computer Science, asked by prajapatipiya75, 5 hours ago

Write a program in java to convert hours in to minutes where hour=14​

Answers

Answered by samridhi299
1

Answer:

import java.util.Scanner;

public class MathUnitConversions14 {

public static void main(String[] args) {

long hours;

Scanner in = new Scanner(System.in);

System.out.println("Please enter hours:");

hours = in.nextLong();

long minutes = hours * 60;

System.out.println(minutes + " Minutes");

}

}

Output:

Please enter hours:

3

180 Minutes..

i hope it will help u

Answered by RitarshiPaul
2

Answer:

class hourstominutes

{

void display ()

{

int hr = 14;

int min = hr*60;

System.out.println ("There are " + min "minutes in 14 hours");

}

}

Similar questions