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
// | |
// LevenshteinDistance | |
// | |
// Created by Kohei Abe on 2017/05/04. | |
// Copyright © 2017年 Kohei Abe. All rights reserved. | |
// | |
import Foundation | |
func levenshteinDistance(_ word1: String, _ word2: String) -> Int { |
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
// | |
// ReverseList | |
// | |
// Created by Kohei Abe on 2017/05/04. | |
// Copyright © 2017年 Kohei Abe. All rights reserved. | |
// | |
import Foundation | |
/// List Element holding 1 character |
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
// | |
// Memoise | |
// | |
// Created by Kohei Abe on 2017/04/20. | |
// Copyright © 2017年 Kohei Abe. All rights reserved. | |
// | |
import Foundation | |
struct CacheData<In, Out> { |