Ad
Fundamentals
Strings
Data Types
Code
Diff
  • def minutes(mins):
        return '{}:{:02}'.format(*divmod(mins, 60))
    • function minutes(minutes){
    • var hours = Math.floor(minutes/60);
    • minutes = minutes - hours*60;
    • return hours.toString() + ":" + minutes.toString().padStart(2, 0);
    • }
    • def minutes(mins):
    • return '{}:{:02}'.format(*divmod(mins, 60))