This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //: Playground - noun: a place where people can play | |
| /*: Quicksort | |
| I wanted to see how closely swift can resemble the Haskell quicksort example | |
| ```` | |
| quicksort :: (Ord a) => [a] -> [a] | |
| quicksort [] = [] | |
| quicksort (x:xs) = | |
| let smallerSorted = quicksort [a | a <- xs, a <= x] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # | |
| git filter-branch --force --index-filter \ | |
| 'git rm --cached --ignore-unmatch PATH-TO-YOUR-FILE-WITH-SENSITIVE-DATA' \ | |
| --prune-empty --tag-name-filter cat -- --all |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import Foundation | |
| import RealmSwift | |
| public struct DataStore | |
| { | |
| public static let sharedInstance: DataStore = DataStore() | |
| private (set) var writeQueue = dispatch_queue_create("nl.mayainteractive.project.realm.write", DISPATCH_QUEUE_SERIAL) | |
| private (set) var mainRealm = try! Realm() |