You are viewing a single comment's thread. Return to all comments →
I did by sorting the list
def birthdayCakeCandles(ar):
ar.sort(reverse=True) for i in range(len(ar)-1): if (ar[i]==ar[i+1]): k=i+1 return k+1
Seems like cookies are disabled on this browser, please enable them to open this website
Birthday Cake Candles
You are viewing a single comment's thread. Return to all comments →
I did by sorting the list
def birthdayCakeCandles(ar):