Skip to content

New Concepts: sorting and/or mutating functions #1043

@depial

Description

@depial

We've yet to explicitly cover sorting and related functions, which has a decent amount of material. Some possible inclusions:

  • sort() / sort!()
  • sort(x, by=function)
  • sortperm()
  • partialsort()

Since there's usually a mutating variant, we could also combine the concept of mutating functions (or also just do a separate concept on that).

I guess the question is where it would come in the syllabus:

  • After Vectors as a leaf
  • After Ranges (since partialsort() can take a range as an argument), either as a leaf or a prereq for Vector Operations
  • Somewhere else?

I'm leaning towards combining the two ideas into a single concept, just we would have to include special emphasis on explaining mutating vs non-mutating functions, the default being non-mutating, and that they can be found for inputs other than just Vectors.

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