0
Trying to solve the final project in Javascript
Hi there I want to solve the final project in Javascript but it doesn't work. My code: class Add { constructor(...words) { this.words = words; } //your code goes here } print(){ var y = ""; for (x of this.words){ if(x = ","){ x = ""; } else { y += "
quot; + x; } y = y + "quot;; console.long(y); } } var x = new Add("hehe", "hoho", "haha", "hihi", "huhu"); var y = new Add("this", "is", "awesome"); var z = new Add("lorem", "ipsum", "dolor", "sit", "amet", "consectetur", "adipiscing", "elit"); x.print(); y.print(); z.print();2 Antworten
+ 2
I think this will you help:
https://code.sololearn.com/Wq22hJlSe5jr/?ref=app
0
Thank you, but it didn't work!