docs: @Override
    public void put(double val, double weight) {
      if(weight == 0.) {
        return;
      }
      if(n <= 0) {
        n = weight;
        sum = val * weight;
        return;
      }
      val *= weight;
      final double tmp = n * val - sum * weight;
      final double oldn = n; // tmp copy
      n += weight;
      sum += val;
      m2 += tmp * tmp / (weight * n * oldn);
    }