Skip to content

Instantly share code, notes, and snippets.

@LuanP
Created October 14, 2015 22:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save LuanP/7564987846fa0b3e978f to your computer and use it in GitHub Desktop.
Save LuanP/7564987846fa0b3e978f to your computer and use it in GitHub Desktop.
import os
import time
def create_file():
with open('/tmp/arquivo', 'w') as f:
f.write('you just found level 3')
def remove_file():
os.remove('/tmp/arquivo')
def loop():
while True:
create_file()
time.sleep(10)
remove_file()
time.sleep(10)
if __name__ == '__main__':
loop()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment