On Sun, May 10, 2020 at 4:00 AM Steven D'Aprano firstname.lastname@example.org wrote:
On Sun, May 10, 2020 at 07:09:15AM +0000, Steve Barnes wrote about Unicode dashes and quotes sneaking into code:
- Tell all users that they need to use a "proper" editor or IDE -
This seems like adding an additional barrier to new & casual users.
When people decide to learn, say, wood working, or carpentry, and try to make holes in timber by gauging the wood with a screwdriver^1 but are told to get themselves a drill instead, is this seen as "an additional barrier" or just part of the process of learning a new skill set?
A cheap drill costs about AUD$50 and another $25 for a set of drill bits. A cheap IDE or programmers editor costs nothing but a bit of time and hard disk space. I think we can expect would-be programmers to *not* use MS Word to write Python code. If they aren't willing to invest the time and energy to install, then they probably won't invest the time and energy to learn how to program either.
Sometimes people are forced to use Word to type code. One example is creating user manuals.
Another example: As a current computer science college student, last fall I had an operating systems professor who gave exams by posting the questions online and giving us 24 hours to write and upload our answers (with the exam being closed-book and on a 2-hour time limit "on the honor system"). Several of the questions required us to write Bash scripts or Python functions, and we were required to write all of that code, along with all of our other exam answers, several of which were essay questions, in Microsoft Word and then export the whole mess as a single PDF file to be uploaded. We were not allowed to submit multiple files, or zip files, or anything at all except one single PDF file containing all of our answers and code.
So no, sometimes people don't get a choice of what to type code in. I would have much rather typed my code in VS Code or Notepad++ and submitted a zip file with the scripts in individual files and the essay responses in a separate Word or PDF file, but that would have earned me a grade of zero on the exams. And yes, several students lost points for syntax errors because Word "helpfully" converted their quotation marks.
I'm happy that professor retired after fall semester and that I'll never have to take another class with him.