Fix queueing example (Python 2 -> 3 thingy?)

This commit is contained in:
Joeri Exelmans 2024-12-11 17:03:11 +01:00
parent bf8ef00b05
commit 4d550b3faa

View file

@ -4,7 +4,7 @@ from pypdevs.DEVS import AtomicDEVS
class QueueState:
def __init__(self, outputs):
# Keep a list of all idle processors
self.idle_procs = range(outputs)
self.idle_procs = list(range(outputs))
# Keep a list that is the actual queue data structure
self.queue = []
# Keep the process that is currently being processed