Add templated binary search, only works for types with equality defined.