as a part of exercising my (basic) python skills i've decided to write short HTML links extractor and combiner, to download a series of lectures on cryptography (which, btw i highly recommend!) to disk. as an experienced C++ developer, having to increment variable, as a part of the loop, i typed:
++i
and… it didn't increment. wtf? quick search showed that python uses “+” and “-” as sign indicators, for number and thus parses “++i” as “+(+i)”, which gives “i”. WAT? and this is how i reminded myself of an short, excellent talk about “nice” pitfalls in rubby and javascript.
good news:
bad news: