Skip to content
This repository was archived by the owner on Jan 5, 2020. It is now read-only.
This repository was archived by the owner on Jan 5, 2020. It is now read-only.

flatten & select #2

@guzhenhuaGitHub

Description

@guzhenhuaGitHub

I tried this in playground:

let count = [1, 2, 3, nil, nil, 4, 5, 6, 7]
.flatten()

and I got an error:

Playground execution failed:

error: RbSwift.playground:1:6: error: cannot invoke 'flatten' with no arguments
.flatten()
^

and I tried this in playground:

let count = [1, 2, 3, nil, nil, 4, 5, 6, 7]
.flatten()
.select { true }

and I got count was a :

[]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions