added comments and naming convention