(min: number, max: number)
| 218 | ]; |
| 219 | |
| 220 | function randomInt(min: number, max: number): number { |
| 221 | return Math.floor(Math.random() * (max - min + 1)) + min; |
| 222 | } |
| 223 | |
| 224 | function sampleOne<T>(values: T[]): T { |
| 225 | return values[randomInt(0, values.length - 1)]; |
no outgoing calls
no test coverage detected