0
I need help with JavaScript Project Content Manager
I found help elsewhere for the code, but it still is not providing a space between the colon after the name and before the number. It comes out like this: ("David",12345) where it should be ("David", 12345) Here's my code: function contact(name, number) { this.name = name; this.number = number; this.print = function(){ console.log(this.name+ ":"+this.number); } } var a = new contact("David", 12345); var b = new contact("Amy", 987654321); a.print() b.print()
2 Antworten
+ 1
Just replace
":"
with
": "
0
thanks!