Added comments; fixed indentation