You are viewing a single comment's thread. Return to all comments →
#python from collections import Counter def happyLadybugs(b): c=Counter(b).items() for x in c: if x[0]!='_' and x[1]==1: return "NO" if '_' not in b: for i in range(len(b)-1): if b[i]==b[i+1] or b[i]==b[i-1]: continue else: return "NO" return "YES"
Seems like cookies are disabled on this browser, please enable them to open this website
Happy Ladybugs
You are viewing a single comment's thread. Return to all comments →