All Questions
1 question
3
votes
1
answer
537
views
Conveniently sorting and (binary?) searching an array of pairs of numbers?
So I have an array of distinct pairs of positive integers. That is, my array looks something like this (for instance):
{ (1,5) , (6,4), (5,3), (2,3), (2,4) }
And my task is, for a given pair (a,b) ...