I am using a Markov chain. When the chain arrives at a particular state, two files (a .png and an .mp3) need to open.
s
is the current state of the chain, an integer from 1-59.
I can't seem to find how to open the file with the same number as 's'.
I'm sure it has something to do with %str
formatting, but I can't seem to implement it.
img = Image.open('/.../.../s.png')
img.show()