You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
170 B

import threading
algo = 0
rlock = threading.RLock()
rlock.acquire()
algo += 1
rlock.acquire()
algo += 2
rlock.release()
rlock.release()
print(algo)

Powered by Informatica FP.