In this episode of the iPhreaks Show the panel interviews, Mischa Hildebrand, asking about a talk he gave at iOS Conf 2019. Mischa has a very varied background, he studied to become a physicist, then did some journalism on television and radio before finally going into iOS development. His background in journalism gave a unique perspective into writing code that is beautiful and easy to understand. Mischa shares principles from his days in journalism and applies them to programming.
The panel shares their experiences working on legacy or unclear code, the describe the pain it was to interpret the code. Mischa’s principles while nothing new address the problems that turn into painful code. First, use short sentences, in other words, keep your lines short. Also, use simple language. The panel discusses what it means to use an active voice versus a passive voice. Another rule is to give one piece of information per sentence, this allows other developers to easily follow the code and its purpose.