According to this [thread][1], the "index" is the built-in variable that can be used in the 
Coveo search result templates. Is there a document that list all available built-in" variables in the scope of result template? especially I needed is to use the total count of the search result to have a logic, inject the survey block after 3rd search result, or append to last if the total count is less than 3. 

```html:

<script class="result-template" type="text/underscore">
    <div>
        {{ if (index == 3 || index == totalCount ) { }}
            <div class="coveo-result-row survey-block">
                 Are these results helpful?
                 <a href="#" class="survey-yes">Yes</a>
                 <a href="#" class="survey-no">No</a>
            </div>
        {{ } }}
    <div>
```

  [1]: https://sitecore.stackexchange.com/questions/3100/coveo-pin-items-between-results