Finished foo (with point-free implementation and doctests)