On 2019-12-10 10:15:45 +, Stephen Tucker wrote:
> I am running Python 2.7.10 on a Windows 10 machine.
Unless you have a really good reason to stick with Python 2.7, don't:
https://pythonclock.org/
The current version of Python is 3.8, and there have been quite a few
changes between 2.x and 3.
On Wed, Dec 11, 2019 at 2:18 AM Stephen Tucker wrote:
>
> Chris,
>
> Many thanks. The first part of your answer was spot on. I have modified the
> program, opening its input file in "rb" mode, and now the program is working
> as I intend it to.
>
Cool!
> I am puzzled by the second part, where
Chris,
Many thanks. The first part of your answer was spot on. I have modified the
program, opening its input file in "rb" mode, and now the program is
working as I intend it to.
I am puzzled by the second part, where you say that the read call will
return one character, if the file is in text mo
On Tue, Dec 10, 2019 at 9:17 PM Stephen Tucker wrote:
>
> I am running Python 2.7.10 on a Windows 10 machine. I have written a Python
> program that counts occurrences of bytes in a text file and have run it on
> a small test file. This file has CR-LF sequences at the ends of its lines.
> The Pyth
I am running Python 2.7.10 on a Windows 10 machine. I have written a Python
program that counts occurrences of bytes in a text file and have run it on
a small test file. This file has CR-LF sequences at the ends of its lines.
The Python program counted the LF bytes, but didn't count any CR bytes.
G