Total Occurrences Of K In A Sorted Array (Facebook Software Engineering Interview Question)