I have a list of bytes as integers, which is something like
[120, 3, 255, 0, 100]
How can I write this list to a file as binary?
Would this work?
newFileBytes = [123, 3, 255, 0, 100]
# make file
newFile = open (directoryPath + newFileCounter + ""filename.txt", "wb")
# write to file
newFile.write(newFileBytes)