Objective: Given an array of integer write an algorithm to find the majority element in it (if exist).

Majority Element: If an element appears more than n/2 times in array where n is the size of the array.

Example:

int [] arrA = {1,3,5,5,5,5,4,1,5};
Output: Element appearing more than n/2 times: 5
int []arrA = {1,2,3,4};
Output: No element appearing more than n/2 times

If you find anything incorrect or you feel that there is any better approach to solve the above problem, please write comment.
__________________________________________________