클래스 정의
class Pencil { constructor(price) { this.price = price; } isExpensive(){ return this.price >= 10; } } //usage const bic = new Pencil(3); bic.isExpensive();
등록된 댓글이 없습니다.
코리아뉴스 2001 - , All right reserved. 더보기