added a little more explaination about code