version-11.0

* consolidated code
* removed repetitive code
* 183 lines to 158