#include #include using namespace std; int findLongestPlayground(vector arr) { int maxCount = 1, currentCount = 1; for (size_t i = 1; i < arr.size(); i++) { if (arr[i] == arr[i - 1]) currentCount++; else currentCount = 1; maxCount = max(maxCount, currentCount); } return maxCount; } int main() { vector arr = {1, 3, 3, 7, 9, 9, 9, 9, 11, 11, 12, 14}; cout << findLongestPlayground(arr) << endl; return 0; }