mirror of
https://github.com/apple/swift-algorithms
synced 2026-11-25 04:27:47 +00:00
33 lines
927 B
Markdown
33 lines
927 B
Markdown
# Trimming
|
|
|
|
Remove unwanted elements from the start, the end, or both ends of a collection.
|
|
|
|
## Topics
|
|
|
|
### Trimming Both Ends of a Collection
|
|
|
|
- ``Swift/BidirectionalCollection/trimming(while:)``
|
|
- ``Swift/BidirectionalCollection/trim(while:)-781az``
|
|
- ``Swift/BidirectionalCollection/trim(while:)-6cbz3``
|
|
|
|
### Trimming from the Start
|
|
|
|
- ``Swift/Collection/trimmingPrefix(while:)``
|
|
- ``Swift/Collection/trimPrefix(while:)-2r8n8``
|
|
- ``Swift/Collection/trimPrefix(while:)-93obt``
|
|
|
|
### Trimming from the End
|
|
|
|
- ``Swift/BidirectionalCollection/trimmingSuffix(while:)``
|
|
- ``Swift/BidirectionalCollection/trimSuffix(while:)-33ubj``
|
|
- ``Swift/BidirectionalCollection/trimSuffix(while:)-3o6x9``
|
|
|
|
### Finding the Suffix of a Collection
|
|
|
|
- ``Swift/BidirectionalCollection/suffix(while:)``
|
|
|
|
### Finding Boundaries within a Collection
|
|
|
|
- ``Swift/Collection/endOfPrefix(while:)``
|
|
- ``Swift/BidirectionalCollection/startOfSuffix(while:)``
|