Added an example file extend.js, updated readme
Implemented context variable `end` for subsets of strings