
Intended for students beginning the study of mechanical engineering design, this book helps students find that the text inherently directs them into familiarity with both the basics of design decisions and the standards of industrial components.
I went to a top tier school for MechE and Materials, and would recommend two intro books: Engineering Mechanics Statics by Meriam and Kriage and Shigley's Mechanical engineering Design in that order . If you fully understand the contents of these book, it probably puts you in the top 10% of mechanical engineering graduates.
For a broader education, you can read Fundamentals of Heat and Mass transfer by Incropera, DeWitt, Bergmann & Lavine as well as Fundamentals of Fluid Mechanics by Munson, Young & Okiishi.
Understanding these two books will probably as well will probably put you in the top 1% of grads.
If you have a strong background in mathematics, these mostly deal with applications of linear algebra and differentials, so the value is understanding the applications.
From there, you can branch out. If applicable, Ogata's Modern Control Engineering and Tongu's Principles of vibration
Most undergraduates dont really understand these due to the heavy application of Laplace and Fourier transforms, but are relevant if you want to build complex machines.
Fluid flow/ thermo would be the other main academic area that this book wouldn't cover.
There's a bunch more topics though that you build over years of intuition- manufacturability, design tradeoffs, etc.
For ICEs we used Ferguson and Kirkpatrick when I took a graduate level ICE class. It's concise but good. I'm not sure it's exactly what you're looking for as a hobbyist though, it's a lot of thermodynamics and associated math, not a lot on practical implementation of engines.
If you're looking to rebuild engines and such "mechanical engineering" is probably the wrong road to go down. I don't have specific recommendations, but maintenance manuals or trainings for mechanics, millwrights a d metal workers might be closer to what you want.
Software Engineering
About C++: The Design and Evolution of C++ and The C++ Programming Language, both by Bjarne Stroustrup, the creator of C++. The first one is a snapshot of his philosophy during early years of C++ and is useful to understand the motivations etc. It provides insight. The second one, after the necessary introduction to the language, shows how he uses C++, or expects to be used, which is interesting in its own way.
About algorithms: Algorithm Design by Kleinberg and Tardos. This gives the much needed insight instead of maths equations, data structure implementations or a catalog of what to apply where, which are all good, but are useless without insight.
Mechanical Engineering (ME is a large field, and I will limit to these two books.)
Stephen Timoshenko's two volume Strength of Materials is a seminal work, and still relevant, on a topic that is at the core of mechanical and civil engineering.
Shigley's Mechanical Engineering Design deals with designing machine parts, which is in a sense an applied strength of materials topic, and the book addresses that part quite effectively, though not as comprehensively as Timoshenko's. More importantly, the book gives enough motivation and insight for the design process, without which engineers would just be "design monkeys" that use latest CAE packages.
Emphasis on properly torqued: in the field threads or bolt heads might be dirty, or torque wrenches might be out of calibration, adding even more uncertainty.