Documentation Methodologies

How do programmers write documentation...