Computer Engineer + iOS Engineer. I am interested in Swift, Kotlin, Firebase, Data Structures, ASO & On Solving Real World Problems.

**Clubhouse** shortly became one of the most popular apps on the AppStore. I would say there's many reasons for the social network growth, one of them, no doubt, is their easy to use interface. Not only easy to use, but also sophisticated and beautiful.

Once in a while I like to review some sorting algorithms, the same with data structures. This week I was reviewing the merge sort.

I followed some tutorials to remind me. You can follow one of them here: https://www.raywenderlich.com/741-swift-algorithm-club-swift-merge-sort

One thing that bothered me is the space necessary for this…

Today, we will talk about how to create an implementation based on event listeners. This implementation will be retain-cycle-free. I will also give a brief description of how event listeners work and why we have to care about retain cycles when implementing them.

Sometimes, you want to notify one or…

I was really interested on this problem of sorting elements. Sorting with heapsort is fast! But it has a big problem: conventionally you have to build a heap to use a heap sort. In a real world usually you don't have a heap mounted to sort whenever. …

I hope you can take a look at my previous piece on heaps, “Let’s Learn About Heaps in Swift,” since heaps are at the heart of this algorithm.

Today we'll discuss a little about the sorting algorithm called *heapsort*. It was introduced in the 60s and is still one of…

In general, heaps are interesting structures for computer science. They sound and look like trees. Usually, the implementation of these guys is made using an array with some helper functions.

I was studying these structures and decided to implement them using Swift. I will be using *Introduction to Algorithms* by…

I was solving this problem a couple days ago and I decided to post it here, so maybe I can help someone facing something similar.

Basically given a two dimensions matrix of numbers, we have to sum the value of the neighbors of an also given index. The index will…

Today I was presented to this problem. Basically given a list of elements, I’d have to find the nearest distance between two elements of that list.

You can see an example of given list. Notice that we’re not talking about a set, which means that elements could possibly repeat.

…

I was curious about some data structures, and the hash table is one of them. I was wondering how I could implement one of these guys using Swift.

They're really powerful data structures when well implemented. Basically their insertion and fetch are made in constant time — **O(1)** if well…