local R=script.Parent local p=R.Parent local E=require(p.t)local d=E.tuple(E.table,E.callback)local function t(R,p)assert(d(R,p))local E={}local t=1 for R,d in ipairs(R)do if p(d,R)then E[t]=d t+=1 end end return E end return t
local List = script.Parent

local Llama = List.Parent
local t = require(Llama.t)

local validate = t.tuple(t.table, t.callback)

local function filter(list, filterer)
	assert(validate(list, filterer))

	local new = {}
	local index = 1

	for i, v in ipairs(list) do
		if filterer(v, i) then
			new[index] = v
			index += 1
		end
	end

	return new
end

return filter