Code for April2014 submission