refactored the code substantially to fix the regression from 'types' to 'type' in the results.  Added some comments and the code is a little shorter too
Merge pull request #37 from JacobGH111/master

PR for Jacob's variety
Merge pull request #36 from todvora/master

Initial version of tests
Update CHANGELOG
Update variety.js
fixing several types of jshint suggestions, but left a few in .jshintrc
tests refactoring (rewritten to java), tested all given examples and more