Question d’entretien chez Roblox

Algorithmic question on sliding window palindrome checking