Some changes
Added comments