Read about how to use the new TabularData library to load and work with csv or json files.
Category Archives: Basics
Refactoring #2
In this post let us look at a piece of code that was written by senior devs trying to consolidate the code. Since I cannot post the code as it is, lets look at portions of the code. The Codebase Say the codebase is common and shared between variants of the app that can be […]
Making a simple Game using Enums
This idea stemmed from the fact that majority of developers create an UI in Interface Builder without an issue, but the real struggle comes when they have to write the code and it was difficult for me to believe at first that writing code or structure is really difficult, so I decided to write these […]
Advanced Usage of Functional Methods
In the last post at reducing-code-for-readability-and-speed which took you through using functional methods instead of loops. The issue was that in some of these functions you might require the index and therefore pushed one back to using loops instead.
Reducing code for readability and speed
In a conversation a couple of days ago, somebody mentioned that they needed to determine the missing digit(checksum) of an ISBN-10 number. This was interesting, specially because this was a perfect example for reducing the lines of code written to resolve this. The specification of ISBN-10 checksum The final character of a ten-digit International Standard […]
Fluency in Chaining Methods – as most refer or understand it as
Do you use fluent interfaces? What? I am fluent in using interfaces … or atleast I think… yeah I am fluent. Now if that was a conversation that made little to no sense, then you are not alone. There are so many words coined for simpler things than expected and that leads to a confusing […]
Exploring Optionals
You can continue reading this article or you can choose not to. Similarly, with variables you can have cases where there is a value or it may not have a value which in other words is nil. Optionals are not applicable to all scenarios. To understand this better, read on…
Move Zeroes – Algorithms
Come across a task in an Interview or a website that challenges you to this. The thing that intrigues me is a good challenge (and many a times I do struggle with it, I am no Genius) However it is still worth a try.
Using Swift techniques for Drawing
The long discussion on is Code an Art or a Science will continue for years to come because there will always be two sides to it and I am not attempting to join or fuel that discussion. However, I feel that in my lifetime I have been lucky to get exposure to a whole lot […]
Validating Strings for Numbers
Swift is gaining popularity with Developers and as companies are considering Swift for their projects. Over a period since the publication of my Swift book (at Swift v1.2) there are many that keep up to date with the new features in Swift and there are those that are now considering the move to Swift or […]