diff --git a/Gruntfile.js b/Gruntfile.js index 4445170..a63cd49 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -42,5 +42,6 @@ module.exports = function(grunt) { grunt.loadNpmTasks('grunt-contrib-watch'); grunt.loadNpmTasks("grunt-jscs"); - grunt.registerTask('default', ['jshint', 'jscs', 'uglify', 'watch']); + // grunt.registerTask('default', ['jshint', 'jscs', 'uglify', 'watch']); + grunt.registerTask('default', ['jshint', 'jscs', 'watch']); }; \ No newline at end of file diff --git a/agile.js b/agile.js index 8c7ef30..4be01c1 100644 --- a/agile.js +++ b/agile.js @@ -52,6 +52,21 @@ } } + /** + * Returns a random number between min (inclusive) and max (exclusive) + */ + function randFromRangeArb(min, max) { + return Math.random() * (max - min) + min; + } + + /** + * Returns a random integer between min (inclusive) and max (inclusive) + * Using Math.round() will give you a non-uniform distribution! + */ + function randFromRange(min, max) { + return Math.floor(Math.random() * (max - min + 1)) + min; + } + /** * Convert object to query string * @return `string`