Java tutorial
//package com.java2s; import java.util.Locale; public class Main { public static String formatDailyTime(int dailyTime) { dailyTime = dailyTime / 1000 / 60; int h = dailyTime / 60; int m = dailyTime % 60; return String.format(Locale.getDefault(), "%02d:%02d", h, m); } }