Added more comments, improved variable names for clarity