Text this: Binary population synthesis: Theory and applications