I have a java.time.Duration and I want to output it in the form of mm:ss. It doesnt seem possible to use DateTimeFormatter since that only accepts LocalTime, ZonedTIme ectera
So I did it like this, works fine for 90 seconds give 1:30, but for 66 seconds gives 1:6 whereas I want 1:06
Duration duration = Duration.ofSeconds(track.getLength().longValue());
System.out.println(duration.toMinutes() + ":" + duration.minusMinutes(duration.toMinutes()).getSeconds());