kelbeyhuebner1864 kelbeyhuebner1864
  • 10-11-2020
  • Computers and Technology
contestada

Write a Python script that prompts the user to enter a number of seconds. Then, calculate the number of hours and minutes and print the result

Respuesta :

Cytokine
Cytokine Cytokine
  • 10-11-2020

secs= int(input("Enter a number of seconds: "))

if secs >= 3600:

   hours = (secs/60)/60

   print("There are {} hour(s) and {} min(s)".format(hours,((hours*60*60)-secs)/60))

else:

   mins = secs /60

   print("There are {} min(s)".format(mins))

I hope this helps!

Answer Link

Otras preguntas

What type of energy is stored due to an objects position or shape; when an object is not moving? A) Kinetic energy B) Chemical Energy C) Thermal Energy D)
Nicole is very interested in photography. She wants to purchase a new camera. It costs $900. She gets paid $400 every two weeks. Write a goal for her.
Ellos____ (jugar, imperfect progressive) futbol cuando se lastimaron. (1 point) A)jugaban B)jugaron C)estaban jugando D)estan jugando
Read this sentence from “The Most Dangerous Game” by Richard Connell, what does the word zealous mean in these lines?
Help SOS ASAP!!!!!!!!??????????:((((((((
In the gilded age, how did monopolies affect many small businesses?
how did the greeks influence my life
after a lucrative career in Hollywood who entered politics and was elected governor of california in 1966
What does casa mean in english
it takes 1.0h to drive 20km through a city during rush hour. your __________seed is 20km/h A. constant B. average C. instantaneous D. accelerating
good job