jQuery.inArray()

Search for a specified value within an array and return its index (or -1 if not found).

.map()

Pass each element in the current matched set through a function, producing a new jQuery object containing the return values.