© 2026 LinearBytes Inc.
Search posts, tags, users, and pages
Mark
The error you got with stdout.write is because you need to pass a single string, not 3 things to be concatenated into a string. I.e.
stdout.write
stdout.write("{}.{}".format(number + 1, book))
The other answer using print is fine too, both ways work.