Easy Solution -beats 90%
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution {\npublic:\n    int getWinner(vector<int>& arr, int k) {\n\n\n        double turns=0,i=0,j=1;\n        if(k>arr.size()){\n            int mn = INT_MIN;\n\n            for( i ; i < arr.size() ; i++){\n                if(mn < arr[i]) mn = arr[i];\n            }\n            return mn;\n        }\n         while ( turns < k )\n         {\n            \n\n            if(arr[0]>arr[j]) { \n                turns++;\n            \n            }\n\n            else{\n                turns=1;\n                i=arr[0];\n                arr[0]= arr[j];\n                arr[j]=i;\n            }\n            if(j+1 == arr.size() ){\n                \n                j = 1;\n            }  \n            else{\n                j++;\n            }\n\n            \n        }\n        return arr[0];\n        \n    }\n};\n```
['C++']