added $map and $filter methods
added tests for $map and $filter methods