Adding comments and documentation