Typos
Added function comments