Skip to content

Swift3.0 support #6

@iceman201

Description

@iceman201
        func convert<S: NumericType>(_ s: S, arr: [S], f: (S) -> S) -> [S] {
            switch arr.match {
            case let .some(h, t):   return [f(h) + s] as! [] + convert(h + s, arr:t, f: f)
            case .none:             return []
            }
        }

I dont know how to re-write this part in swift 3

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions