hilosConPython/ejercicios_hilos/ej02.py

16 lines
278 B
Python

import threading
import time
def escribePunto():
for i in range(100):
print (".", end="",flush=True)
time.sleep(0.1)
return
print ("INICIO")
t = threading.Thread(target=escribePunto)
t.start()
for i in range(50):
print ("-", end="",flush=True)
time.sleep(0.2)