added currying and uncurrying.