Wednesday, October 17, 2012

Count occurrence of an element in a Sorted Array

Given an array of sorted elements, count the number of times a given element is repeated. The solution cannot be linear.

Solution:- Have given 2 solutions, both are modifications to binary search

No comments:

Post a Comment

UA-36403895-1