'How do you find an element strictly less than integer c in an unordered_set without looping through the whole thing
I have an unordered_set of integers and I want to see if there is an element strictly less than an integer c that exists. I want to use unordered_set::find but since I'm not finding a single number, how am I able to do this. I could iterate through the entire set but that would take too long. Any help would be appreciated.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
