You are viewing a single comment's thread. Return to all comments →
python3
def funnyString(s): arr = [ord(c) for c in s] i, j = 0, -1 while i+1 < len(arr)//2+1: if abs(arr[i+1]-arr[i]) != abs(arr[j]-arr[j-1]): return "Not Funny" i += 1 j -= 1 return "Funny"
Seems like cookies are disabled on this browser, please enable them to open this website
Funny String
You are viewing a single comment's thread. Return to all comments →
python3