[javascript] Immutable.js에서 사용할 수 있는 집계 메소드에는 어떤 것들이 있나요?
  1. size(): Immutable 객체에 있는 항목의 개수를 반환합니다.
    const list = Immutable.List([1, 2, 3, 4, 5]);
    console.log(list.size()); // 5
    
  2. count(): 지정된 조건을 만족하는 항목의 개수를 반환합니다.
    const list = Immutable.List([1, 2, 3, 4, 5]);
    console.log(list.count(value => value > 2)); // 3
    
  3. sum(): Immutable 객체에 있는 숫자 항목들의 합계를 반환합니다.
    const list = Immutable.List([1, 2, 3, 4, 5]);
    console.log(list.sum()); // 15
    
  4. min(), max(): Immutable 객체에 있는 숫자 항목들 중 최솟값과 최댓값을 반환합니다.
    const list = Immutable.List([1, 2, 3, 4, 5]);
    console.log(list.min()); // 1
    console.log(list.max()); // 5
    
  5. average(): Immutable 객체에 있는 숫자 항목들의 평균값을 반환합니다.
    const list = Immutable.List([1, 2, 3, 4, 5]);
    console.log(list.average()); // 3
    

이 외에도 다양한 집계 메소드가 있으며, Immutable.js 문서에서 자세한 내용을 확인할 수 있습니다. 참조 문서