Fix saving and loading
This commit is contained in:
parent
4fc83cff57
commit
32e320b820
1 changed files with 2 additions and 0 deletions
|
|
@ -1,4 +1,5 @@
|
|||
import sys
|
||||
import json
|
||||
import random
|
||||
|
||||
class Markov:
|
||||
|
|
@ -29,6 +30,7 @@ class Markov:
|
|||
before = random.choice(list(self.matrix))
|
||||
|
||||
selection = self.matrix[before]
|
||||
print(repr(before), repr(selection))
|
||||
choice = random.randrange(sum(selection.values()))
|
||||
|
||||
counter = 0
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue