Return Array with all Palindromes Found in String

You are given a lowercase string, which contains at least one 2 or 3 character palindrome as an argument. Return an array of strings containing all the palindromes found in the argument string.

Palindromes are strings that form the same word if it is reversed.


  • Must return an array of strings

Example #1

> ['aba', 'aba']

Example #2

> ['rdr','eke','aca']