题解 | JS26 Getter

        class Rectangle {
            // 补全代码
            constructor(height,width){
                this.height = height,
                this.width = width
            }

            get area(){
                return this.height * this.width;
            }
        }
全部评论

相关推荐

舞台少女神顺光:🐟小c的一选也只有一个hc,飞哥值得
点赞 评论 收藏
分享
点赞 收藏 评论
分享
牛客网
牛客企业服务