Skip to content

Unitalicize "log" in big O notation #17

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 12, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Guides/Partition.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,13 +74,13 @@ extension Collection {
### Complexity

The existing partition is an O(_n_) operations, where _n_ is the length of the
range to be partitioned, while the stable partition is O(_n log n_). Both
range to be partitioned, while the stable partition is O(_n_ log _n_). Both
partitions have algorithms with improved performance for bidirectional
collections, so it would be ideal for those to be customization points were they
to eventually land in the standard library.

`partitioningIndex(where:)` is a slight generalization of a binary search, and
is an O(_log n_) operation for random-access collections; O(_n_) otherwise.
is an O(log _n_) operation for random-access collections; O(_n_) otherwise.

### Comparison with other languages

Expand Down