Skip to content

Instantly share code, notes, and snippets.

View schani's full-sized avatar
⌨️
I just sit at my computer and curse a bit.

Mark Probst schani

⌨️
I just sit at my computer and curse a bit.
View GitHub Profile
@schani
schani / blocks.json
Last active March 6, 2018 15:09 — forked from dvdsgl/blocks.json
Examples of maps vs classes classified by quicktype Markov chains
{
"0000000000000000000e222e4e7afc29c49f6398783a94c846dee2e13c6408f5": {
"size": 969709,
"height": 510599,
"difficulty": 3007383866429.732,
"previous": "000000000000000000552a7783efd39eaa1c5ff6789e21a0bbe7547bc454fced"
},
"000000000000000000552a7783efd39eaa1c5ff6789e21a0bbe7547bc454fced": {
"size": 991394,
"height": 510598,
@schani
schani / SwiftSet.swift
Last active August 13, 2018 05:07 — forked from algal/SwiftSet.swift
struct MySet<KeyType : Hashable> : Sequence, ArrayLiteralConvertible
{
var dictionaryOfItems = Dictionary<KeyType,Bool>()
typealias GeneratorType = MapSequenceGenerator<Dictionary<KeyType, Bool>.GeneratorType, KeyType>
init() {}
init(array: KeyType[]) {
for item in array {
self.dictionaryOfItems.updateValue(true, forKey: item)
}