I like how explicit you are in building your tran_str. There's probably a way to do it without building a list and turning it into a string, but it seems to work just fine.