(bufferLength)
| 30 | |
| 31 | class MovingAverager { |
| 32 | constructor(bufferLength) { |
| 33 | this.buffer = []; |
| 34 | for (let i = 0; i < bufferLength; ++i) { |
| 35 | this.buffer.push(null); |
| 36 | } |
| 37 | } |
| 38 | |
| 39 | append(x) { |
| 40 | this.buffer.shift(); |
nothing calls this directly
no outgoing calls
no test coverage detected