• How to repeat a string in Swift 4

    How to repeat a string in Swift 4

    Ever wanted to repeat a string x number of times? There is a simple way to do it in Swift 4. Check it out: let numberOfRepeats = 3 String(repeating: “stringToRepeat”, count: numberOfRepeats) So the “stringToRepeat” will repeat numberOfRepeats times.

  • How To Change Navigation Bar Color iOS Swift 5

    How To Change Navigation Bar Color iOS Swift 5

    Sometimes you will want to change the color of your navigation bar for branding purposes, and it is actually pretty easy to do. Use the following snippet in your view controller in viewDidLoad to change the color you would like. // get the navigation bar from the current navigation controller if there is one let
    Read More…




  • How To Customize UITabBar Icon Highlight Color iOS Swift 5

    How To Customize UITabBar Icon Highlight Color iOS Swift 5

    So Tabbed applications are pretty common nowadays. It is a great design pattern to follow when you are setting up your application. One of the customizations I was trying to accomplish today was to make the icon highlight in different colors. Personally, I wanted my current tab to show up in orange instead of blue,
    Read More…

  • How To Use List Of Objects With User Defaults iOS & Swift 4

    How To Use List Of Objects With User Defaults iOS & Swift 4

    Ever wanted to store a list of objects into user defaults for reference later? Lets check out the below code to do just that. // to retrieve arrays from user defaults UserDefaults.standard.array(forKey: “yourArrayKey”) // to store arrays of objects into user defaults UserDefaults.standard.set(arrayToStore, forKey: “yourArrayKey”) // to delete the object from your user defaults UserDefaults.standard.removeObject(forKey:
    Read More…

  • How To Display An Alert In iOS & Swift 5

    How To Display An Alert In iOS & Swift 5

    In iOS, there will be times where you will want to give the user some feedback depending on the situation. It could be because of a success or a failure whether it be during object creation or authentication. Below is a code snippet to create an AlertViewController and then present it. We can add actions
    Read More…

  • Introduction to Core ML

    Introduction to Core ML

    In the introduction to the new framework at WWDC 2017, the speakers made some interesting revelations. Check out my notes below: CoreML is a lower level library that offers a bunch of prebuilt models such as SVMs, Neural Networks, Random Forrests etc… If you don’t want to work at the model level, there are 2
    Read More…