Output class docs in markdown
Simplify loops using func.bind1