Add map() and flatmap()

As discussed in #11.
Could we please construct these with `reduce` instead?

```swift
return reduce(self, Set<Result>()) {
	$0 + transform($1)
}
```

should do it.