강의

멘토링

커뮤니티

Inflearn Community Q&A

csh94119345's profile image
csh94119345

asked

Introduction to Javascript Algorithm Problem Solving (Coding Test Preparation)

5. Kth largest number

set 객체를 사용한 이유?

Written on

·

185

0

let tmp = new Set()

이 잘 이해가 가지 않습니다. 

여기서 set 객체를 사용하신 이유가 있나요?

mdn 사이트 보니까 중복은 추가하지 않던데 그런이유 때문에 사용하신건가요?

코테 준비 같이 해요! javascript

Answer 1

0

codingcamp님의 프로필 이미지
codingcamp
Instructor

안녕하세요^^

네. 맞습니다. 중복을 제거하기 위해서 Set 자료구조를 사용한 것입니다.

csh94119345's profile image
csh94119345

asked

Ask a question