(min, max)
| 814 | |
| 815 | // Return a random integer between `min` and `max` (inclusive). |
| 816 | function random(min, max) { |
| 817 | if (max == null) { |
| 818 | max = min; |
| 819 | min = 0; |
| 820 | } |
| 821 | return min + Math.floor(Math.random() * (max - min + 1)); |
| 822 | } |
| 823 | |
| 824 | // A (possibly faster) way to get the current timestamp as an integer. |
| 825 | var now = Date.now || function() { |
no outgoing calls
no test coverage detected
searching dependent graphs…