Well, it would be best ideally if you write the code yourself so you understand how it works, but...
# get your time and place it in a variable. We'll use
# the variable below for an example
var time_in_seconds = 410
# we need a variable to know how many
# minutes we have. We'll reuse time_in_seconds
# to get the seconds.
var time_minutes = 0
# while there is more than a minute left:
while time_in_seconds > 60:
# Add a minute and remove 60 seconds
time_minutes += 1
time_in_seconds -= 60
# Now we have the minutes and time_in_seconds
# is the remaining seconds.
# Finally, let's print the result in the minutes:seconds format:
var result_string = ""
# If there are no minutes, then add a zero, otherwise convert
# the minutes to a string.
if (time_in_minutes > 0):
result_string += String(time_in_minutes)
else:
result_string += "0"
# Add a colon
result_string += ":"
# Add the seconds directly if they are double digit.
# if they are not double digit, then add a zero first.
if (time_in_seconds > 9):
result_string += String(time_in_seconds)
else:
result_string += "0" + String(time_in_seconds)
# print the result
print ("Time is: ", result_string)