Skip to content

Bug in callback.js solution #24

Description

@anluik

The union method does not remove duplicates from the first array in arrays as the challenge requires: "If there are duplicate elements, only add it once to the new array".

Here, the expected result would be [1, 2, 3], but is [1, 1, 2, 3]

const result = union([[1, 1, 2], [2, 3]]);
console.log(result);

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