sorted

a a1
a a2
a a3
b b1
b b2
b b3
c c1
c c2
d d1
d d2
d d3
d d4

In this list, the formula will be able to find the first and the last occurrence of a letter and will be able to return the neighboring cells as one contiguous range, which can be used in a data validation list.

In an unsorted table

a a1
b b1
c c1
a a2
b b2
c c2
a a3
b b3
d d1
d d2
d d3

it is not possible to form one contiguous reference for the data validation list, and the list between the first b and the last b will contain many other things, not just b1, b2, b3

Do you see what I mean?

cheers