For a size n sorted array of strings, binary search would take O(log n) in terms of n. However, what would be the run time in terms of the length of strings?
The complexity of string comparison is linear time with respect to the string length, so, in this case, letting m = string length, the complexity would be