+ 2

help me with this question please

Fill in the blanks to declare a class Point with a constructor initializing its x and y members. Point { (a, b) { this.x = a; this.y = b; } getX() { return this.x; } getY() { return this.y; }

2nd May 2020, 4:19 PM
Ahmed
Ahmed - avatar
5 Answers
+ 6
class Point { constructor(a,b){ this.x = a; this.y = b; } getX() { return this.x; } getY() { return this.y; } } This is the corrected code :))
2nd May 2020, 4:22 PM
Arb
Arb - avatar
+ 1
class Point { constructor(a,b){ this.x = a; this.y = b; } getX() { return this.x; } getY() { return this.y; } }
2nd Mar 2022, 6:09 AM
Pascal Elisée BALOKI
Pascal Elisée BALOKI - avatar
0
Class Constructor }
25th Jul 2020, 4:10 PM
Ekundayo Timileyin
0
deje myMap = nuevo Map (); myMap.set ('cero', ); mi mapa. ('uno 1); (deje [clave, valor] de myMap) { console.log (`$ { } = $ {value} `); }
28th Jul 2020, 7:18 AM
Eder Teran
Eder Teran - avatar
0
class Point { constructor (a, b) { this.x = a; this.y = b; } getX() { return this.x; } getY() { return this.y; } }
3rd Dec 2020, 7:39 PM
El Maslohi Hassan