William Pritzker
WPritzker
Published in
1 min readSep 3, 2018

--

Syntax Errors — and Dealing with them

In my second month of learning to code I have found the single biggest obstacle to continued success to be syntax errors. Rather that focusing on big concepts, the majority of my time in the text editor has been spent scouring for a missed comma or quotation mark that threw everything off. This is all the more frustrating as a beginner. Not only am I looking for the instant gratification of a successful code, I do not yet have the experience to know my fundamentals are sound. These are the strategies I have used to help:

1: Review error messages — Typically the error message will point out the line in which the code needs to be corrected in this instance. However, often the error message disguises the actual issue. In this case…

2: Use color codes — Colors in text editors exist only to help prevent typing errors. Use them!

3: Retype what has changed in the code — Hopefully, this will only be a few lines but often I identify a missing comma or spelling error that I had previously not caught.

4: Tell your rubber ducky what your code is trying to accomplish — You may find that the error isn’t in fact from syntax.

--

--