Hello, checkiomates🐱👤!
This week's digest explores the path to mastery, defining what truly makes a developer senior beyond years of experience. We also break down the SOLID principles for better Python design and dive deep into the internals of dataclasses. Our mission is a fundamental logic test: identify if an integer is positive, negative, or zero.
💡TIP
We allow users to assign hotkeys to "Run Code", "Check Solution" and stop code. You may see current combinations on buttons and change them in editor menu. If you want to discover all CheckiO features, visit our tutorial. It's a longread, but it's worth it!
🏁 MISSION
Integer Sign Determination by freeman_lex -
Identify whether a given integer is positive, negative, or zero and return a respective string: "positive", "negative" or "zero".
determine_sign(5) == "positive" determine_sign(0) == "zero" determine_sign(-10) == "negative"
📖 ARTICLES
What Actually Makes You Senior -
This opinion piece argues that there is one skill that separates senior engineers from everyone else. It isn’t technical. It’s the ability to take ambiguous problems and make them concrete.
SOLID Design Principles: Improve Object-Oriented Code in Python -
Learn how to apply SOLID design principles in Python and build maintainable, reusable, and testable object-oriented code.
The Inner Workings of Python Dataclasses Explained -
Discover how Python dataclasses work internally! Learn how to use __annotations__ and exec() to make our own dataclass decorator!
👩💻CODE SHOT
What do you think the following code does?
checkio= lambda c1, c2: len({round(a/b, 2) for a, b in zip(dist(*c1), dist(*c2))}) == 1
dist = lambda a, b, c: sorted([hyp(*a, *b), hyp(*a, *c), hyp(*c, *b)])
hyp = lambda a, b, c, d: __import__("math").hypot(a - c, b - d)
🙌 Thanks for your attention! Hope to meet you at CheckiO, as well as at our Instagram and Twitter! We are really interested in your thoughts! Please, leave a comment below! ⤵
