answersLogoWhite

0

You do a integer division, minutes divided by 60, keeping in mind integers do not use decimal points. The integer result is the hours. Then you do a remainder or Modulus (%) of the minutes by 60 to get the remainder in minutes.

Java:

Int hours, minutes=140, minutesresults;

hours=minutes/60; //result is 2 hours

minutesresults=minutes%60; //result is 20 minutes

Calculator:

A calculator is normally not equipped to do an integer division directly. Dividing 140/60 gives you 2.333. The 2 becomes the hours then take the decimal part (.33) and multiply it by 60 (result 19.8 or 20 rounded to an integer value is the minutes).

User Avatar

Wiki User

7y ago

What else can I help you with?