摘要:
队列: 先进先出 后进先出 VIP(优先级) import queue # q = queue.LifoQueue()#后进先出 # # q.put(1) # q.put(2) # q.put(3) # print(q.get()) # print(q.get()) # print(q.get()) 阅读全文
摘要:
import time,threading event = threading.Event() def lighter(): count = 0 event.set() while True: if count > 5 and count < 10:#改成红灯 event.clear()#把标志位清 阅读全文