Style guide

Added a programming style guide and some basic comments.