add binary search template