CitiusTech Interview Question

Find the frequency of each element in an array.