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 […]

Programming Swift like Swift not Java or Objective-C

The last article was written around September 2015 and a lot has happened in the world of Swift since then including my world (both of which are for another time/article). However in the last couple of months I have been interviewing developers to work with us and the interesting fact that emerges from the technical […]

Convert Binary String to Integer

How do you convert Binary String to it’s Integer Value? There are many approaches to convert Binary strings to Integers. One approach could be to iterate through all of the characters in the string and add the value of 2 raised to the power of the index.

Chaining cout in swift like C++

In an earlier article, we discussed the possibility of adding a cout like functionality in Swift as seen in C++ (https://swift.oz-apps.com/2015/04/using-a-cout/). There were a couple of impediments that prevented the full functionality of our cout function. Let us revisit that and add chaining

WIP: Use Swift Arrays like Lua Tables

This is work in progress and there are somethings that Swift cannot do where as Lua excels with them. Since everything in a Lua table is a reference or a pointer, you can recursively add table to refer to subtables. You could also store functions in the tables and invoke them based on the key. […]

Tip: Creating an Int from a String in Swift

Talking to a couple of developers over various mediums about Swift has had mixed results. However one thing that came up again and again was that it is a little confusing. While confusing in the literal sense would not be the correct word. So let me elaborate the issue first.