Find Repeating Element In Sorted Python