Big O notation is a tool we use to estimate how long a program or an algorithm will run. On this blog we’ve covered a lot of algorithms but we only touched on the big O notation. If you have a degree in computer science then you’re probably familiar with… Read more »
Enigma Machine was a famous cipher machine that the germans used during the World War 2. In its time it was believed to be uncrackable. Allied forces managed to crack the enigma machine during the war and Alan Turing played a key role in cracking it. In this article we’ll… Read more »
Bellman-Ford algorithm is a very versatile algorithm for finding the shortest path on an edge weighted directed graph. It differs from Dijkstra’s algorithm in that it can handle the negative cycles on the graph. In this article we’ll implement the Bellman-Ford algorithm in swift and with it conclude our journey… Read more »
Edge weighted digraphs can be used for a large number of things. In some cases we want to know if there’s a directed cycle between the nodes (or vertices). For example, if we’re working on a scheduling app, we would be interested to know if there’s a cycle on the… Read more »
Last week we’ve talked about edge weighted digraphs in swift. This week we’ll talk about a famous algorithm that’s using that data structure. Dijkstra’s algorithm is a simple and well-known algorithm for finding a shortest path between two points on a graph. In this article we’ll implement Dijkstra’s algorithm in… Read more »
Long long time ago, when I was a student, I wrote a paper on genetic algorithms. This is a really exiting topic for me and I always wanted to create something for iOS using genetic algorithms. This article was a long time coming, I hope you’ll enjoy it… Traveling salesman… Read more »
I’ve read a great book recently. Algorithms Fourth Edition by Robert Sedgewick and Kevin Wayne. This is a great book that reminded me of my college days when I was listening to my Algorithms and Data Structures. This book is written as a text-book, and is very technical. So if… Read more »
There are more than a few search algorithms. Today we’ll examine one of them, the Binary Search Algorithm, and we’ll implement this algorithm using an array extension in swift. We’ll also compare the performance of this algorithm to your standard brute force search, and see how it compares. Binary Search Algorithm… Read more »
Sorting algorithms are an important feature of modern computing, and in this article we’ll examine some of the most common sorting algorithms in use today. Implementations of these algorithms will be done in swift, but they are language agnostic, and you should have on problems implementing them in a language… Read more »
In computer science there are many data structures. In this post we will examine one such structure called a ‘Stack’. We’ll implement it using another data structure called a ‘Linked List’, and for the sake of comparison, we will implement the same stack data structure using plain old arrays, and… Read more »