-
Notifications
You must be signed in to change notification settings - Fork 178
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use "Builder"s to implement the functions: * Set.fromList * Set.map * Map.fromList * Map.fromListWith * Map.fromListWithKey * Map.mapKeys * Map.mapKeysWith As a result, * All fromList functions above are now good consumers in terms of list fusion. * Set.fromList and Map.fromList are now O(n) for input in non-decreasing order. They were already O(n) for input in strictly increasing order. * Map.fromListWith and Map.fromListWithKey are also O(n) for input in non-decreasing order. * Set.map, Map.mapKeys, Map.mapKeysWith are O(n) if the mapping is monotonic non-decreasing.
- Loading branch information
Showing
3 changed files
with
167 additions
and
150 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.