local I=script.Parent local t=I.Parent local c=require(t.t)local Z=c.tuple(c.table,c.callback)local function s(I,t)assert(Z(I,t))local c={}for I,Z in pairs(I)do local s,J=t(Z,I)c[J or I]=s end return c end return s
local Dictionary = script.Parent

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

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

local function map(dictionary, mapper)
	assert(validate(dictionary, mapper))

	local new = {}

	for key, value in pairs(dictionary) do
		local newValue, newKey = mapper(value, key)
		new[newKey or key] = newValue
	end

	return new
end

return map