Java List Sum sumLog(List Q)

Here you can find the source of sumLog(List Q)

Description

sum Log

License

GNU General Public License

Declaration

public static float sumLog(List<Float> Q) 

Method Source Code

//package com.java2s;
/*/*from ww w.  j a  v  a  2 s  . c  o  m*/
 * Copyright 2015, Yahoo Inc.
 * Copyrights licensed under the GPL License.
 * See the accompanying LICENSE file for terms.
 */

import java.util.List;

public class Main {
    public static float sumLog(List<Float> Q) {
        float res = 0;

        for (float f : Q) {
            res += Math.log(f);
        }

        return res;
    }
}

Related

  1. sumDifferences(List a, List b)
  2. sumDouble(List list)
  3. sumInteger(List list)
  4. sumIntegers(List values)
  5. sumListItems(List list)
  6. sumLong(List list)
  7. sumOfSquares(List samples)
  8. sumOfSquares(List list)
  9. sumTerms(List terms)