Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
algoritmo utilizado 
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
import random 
class Queue: ...
flowChart: banks 
average waiting 
time class items. 
methods 
__init__ tick 
state 
average = parameter 
attended = None ...
bank 
init 
tick 
busy 
startNext 
task 
Init 
1 parameter 
waitTime 
getStamp 
getClient 
main 
newTask 
simulation 
2 pa...
Upcoming SlideShare
Loading in …5
×

flowChart

357 views

Published on

python average simulation beta flowChart.

Published in: Education
  • Be the first to comment

  • Be the first to like this

flowChart

  1. 1. algoritmo utilizado # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - import random class Queue: def __init__(self): self.items = [] def isEmpty(self): return self.items == [] def enqueue(self, item): self.items.insert(0,item) def dequeue(self): return self.items.pop() def size(self): return len(self.items) # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - class Bank: def __init__(self, cph): self.average = cph self.attended = None self.timeRemaining = 0 # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - def tick(self): if self.attended != None: self.timeRemaining = self.timeRemaining - 1 if self.timeRemaining <= 0: self.attended = None # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  2. 2. flowChart: banks average waiting time class items. methods __init__ tick state average = parameter attended = None timeRemaining= 0 startNext busy bank task methods __init__ getStamp getClients waitTime state client = numberRandom timeStamp = parameter simulation task
  3. 3. bank init tick busy startNext task Init 1 parameter waitTime getStamp getClient main newTask simulation 2 parameter flowChart: banks average waiting time classes methods. main Giovannie Sanchez Juan Rosado methods simulati on run newT ask state

×