cleaned up syntax errors

Cleaned up a few things so now it runs. Deleted an unneeded closing
parenthesis on line 52 (had to do some re-indenting to find that,
sorry…), and changed the two instances of ”var const” to just “const”