0

I am having problems with node.js REPL. I put in the following line into the node REPL:

var p = {fname: "john", lname= "Doe"}

What I get back is an ellipsis (...) as if REPL is waiting for a continuation. I also try to put a ; at the end, or taking the var keyword out, but get the same result.

Why does it think that it is not the end of a statement? What am I missing?

env: Node version 0.6.2, running on windows.

Thanks.

1 Answer 1

4

Your syntax is wrong, it should be:

var p = {fname: "john", lname: "Doe"}

(note the : instead of =)

Sign up to request clarification or add additional context in comments.

1 Comment

Dang, I just spent two hours on the #$#@# thing. Thanks!!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.