Project

General

Profile

Actions

Refactor #10584

closed

Replace sort.uniq with uniq.sort

Added by Tomer Brisker almost 9 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Performance
Target version:
Difficulty:
easy
Triaged:
Fixed in Releases:
Found in Releases:

Description

Sort usually runs in O(nlogn) while uniq runs in O(n).
If n is reduced by uniq it will improve the runtime, otherwise it will make no significant difference.

Actions

Also available in: Atom PDF