Company: Visa__...
Difficulty: medium
Compare Counts Problem Description You are given an array of integers numbers and an integer pivot . Let countGreater denote how many integers within numbers are strictly greater than pivot , and countLess denote how many integers are strictly less than pivot . Your task is to compute countGreater and countLess , then return: "greater" if countGreater is greater than countLess ; "smaller" if countGreater is less than countLess ; "tie" if they are equal. Note: You are not expected to provide the most optimal solution, but a solution with time complexity not worse than O(numbers.length^2) will fit within the execution time limit.