Computer Science, asked by shivangipandey048, 1 year ago

write a program that ask the user to input no of seconds and then express it in terms of minutes and seconds​

Answers

Answered by chiefprashant
5

Answer:

#Python

Explanation:

s = int(input("seconds "))

min = s/60

sec = s%60

print(min, ":", sec)

Answered by AskewTronics
3

Below are the program for the above question:

Explanation:

seconds=int(input("Enter the number of seconds"))#Enter the value of the seconds.

minute=int(seconds/60)#change the value of seconds in minute.

seconds=int(seconds%60)

print("The minute is "+str(minute)+" and the second is "+str(seconds))# It is used to print the value of minute and the seconds.

Output :

  • If the user inputs as 4480, then the output is 74 for minute and the 40 for the seconds.
  • If the user inputs as 4480, then the output is 74 for minute and the 0 for the seconds.

Code Explanation:

  • The above code is in python language which renders a message to the user, take the input from the user and then convert it into minute and seconds.
  • Then the minute and the second value are printed by the print function.

Learn More:

  • Python : https://brainly.in/question/14689905
Similar questions