Created
December 21, 2017 12:59
-
-
Save infrony/1b89e5e21a431b1eed959efcb39d0198 to your computer and use it in GitHub Desktop.
Simple Alarm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import time | |
dormir = input (" Segundos para activar la alarma :") | |
audio = ("start C:/code/python/alarm.mp3")#cambiar la ruta del archivo de audio | |
time.sleep (int(dormir)) | |
os.system(audio) | |
z = input("Presione la tecla z para seguir durmiendo : ") | |
if z == "z": | |
time.sleep (5) | |
os.system(audio) | |
else : | |
print ("Alarma Cancelada ! (r,)") | |
print ("Alarma Apagada") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment