I have zero knowledge in JS or JQuery and am learning to do so

I am trying to update my code that will help me do the following

I am trying to achieve the following points, at once : 

1. When you click on the anchor link, the page moves the content to the top of the page.
2. When you click on the expand for a object, the others collapses

I have finally compiled this code here 

[**Click here to view the link**](http://codepen.io/anon/pen/OMYLNb) 

```
Please help me in achieving both the points

```

Thanks for your efforts