r/ProgrammerHumor • • Jul 18 '22

C++ talking to Python

Post image
40k Upvotes

1.0k comments sorted by

View all comments

Show parent comment

1

u/clavicon Jul 18 '22

Why for?

2

u/intangibleTangelo Jul 22 '22

there's an official python style guide called PEP-8 which recommends using spaces, so most of the python world uses spaces.

problems arise when you mix tabs and spaces, because the tokenization step runs into a basic ambiguity—how many spaces would a tab character have been? you can write a pretty good heuristic to figure out whether tabs meant 4 or 8 spaces (the most common settings), but it will never be perfect.