/**
   * 1. new Set() 사용하기
   */
  const items = [1, 4, 2, 3, 1, 5];
  const uniqArray = array => [...new Set(array)];

  console.log(uniqArray(items));
  /**
   * 2. Array.filter 사용하기
   */
  const items = [1, 4, 2, 3, 1, 5];
  const uniqArray = array => array.filter((item, index) => array.indexOf(item) >= index);

  console.log(uniqArray(items));