Duck typing and the importance of good public interfaces
If it walks like a duck and it quacks like a duck, then it must be a duck
We saw in a previous article that it’s much better to depend on abstractions than on concrete classes. Concretions are more likely to change than abstractions, and those changes will ripple through our codebase affecting all the classes that depend on them.
We also lear...
Things I wish I had known when I started programming, Part 1
Learning to program is a long journey, and it can take years of constant effort to become good at it.
When I started writing my first lines of code, I felt super excited that I could make a machine do things. Granted, they were very simple things, but I felt I could achieve anything with this cool new skill. After a while, I started to notice t...
Dependency Injection and the famous DIP
Dependency injection is one of those techniques that carry around a bad reputation for being overly complicated and hard to understand. In reality, DI(you guessed it, dependency injection) doesn’t need any complex framework or fancy library to be useful, you can start using it very easily.
Let’s start with an example class Robot, that uses an a...
Welcome to Brains To Bytes
Hello!, and welcome to Brains To Bytes.
Software development is an incredibly exciting field full of opportunities and great ideas. It’s also unlike lots of other crafts in an important sense: the end product, instead of being a tangible thing, is materialized thought running inside a chip.
This notion of programming as a translation of your i...
84 post articles, 11 pages.