Microsoft Interview Question

Anonymous User
939
Oct 05, 2023

Given a sorted string "aaabbbccccccceeee" and a character, write a function to return the frequency of character. Time Complexity expected was O(logN) and Space complexity O(1).
How to solve this?

Comments (10)