To implement the custom search

hi guys, i want implement a search in my app,
but i need some modification on my search
my list =[‘a’,‘ab’,‘aab’,‘bab’,‘baab’,‘ac’,‘aba’]
in my search when type "ab"
the list shows only ab and aba. not with aab,bab,baab.

it search my input only from first index. not from any where in my string.

help me with some logics,soon it will be better…