Saw this from some Amazon reviews of the Python version of EPI: > The coding style in many cases is just... bad. The authors often use wonky Python tricks at the cost of readability and simplicity. For example, their definition of a BST search is a *one-line* nested ternary conditional (chapter 14, page 202). I sanity-checked with a friend who does interviews, and he said he would DOCK points for style if a candidate tried to pull something like that. In addition, the explanations in many sections are just confusingly worded. And sometimes, the presented solution is completely unintuitive or badly styled - like using global variables instead of passing parameters. > The authors mention that the code solutions are "Pythonic". However, this is not the case. In fact a lot of the code in this book seems to be written by someone who doesn't seem to grasp pedagogy. See the solution for string to int: def string_to_int(s): return functools.reduce(lamba running_sum, c: running_sum * 10 + string.digits.index(c), s[s[0]] == '-', 0) * (-1 if s[0] == '-' else 1) Are you kidding me? How is this solution even remotely pedagogical, or even an acceptable solution in a coding interview? --- That sounds pretty bad. Are the Java or C++ versions any better? I'm hoping at least the C++ one is since it's OG. If not then might as well skip EPI and focus on LC.
The C++ one has style issues as well.
Bang on. This was my major gripe with the book. Too much emphasis on making the code extremely concise at the cost of readability. I don't really understand why this book gets so much hype.
Guess it was a bigger deal before Leetcode came out, when problem sets + explanations was just limited to CTCI (which also suffers from forcing conciseness at the expense of clarity in some explanations imo) and GeeksforGeeks (which has very inconsistent explanation quality).
Tech Industry
2d
2331
NW required for "fuck you money"
Ask Blinders
17h
760
Why Pronouns shit captured US ? I don’t see this anywhere else
AMA
Yesterday
2848
I have worked at TikTok US core tech for 3 years. AMA.
Cars
Yesterday
1771
Cyber truck killer: Chinese version of EV truck
India
Yesterday
1006
Any Indians Think Kashmir Should be Independent?
can find some pdf online