Re: [nodejs] Node issue - prints 'undefined' for any action.

22 views
Skip to first unread message

Ben Noordhuis

unread,
Oct 10, 2012, 10:57:47 AM10/10/12
to nod...@googlegroups.com
On Wed, Oct 10, 2012 at 9:29 AM, ketan mehta <ketan...@gmail.com> wrote:
> Hi,
> I am using Window 7 and I have installed Node.js from
> http://nodejs.org/download/ (Windows Installer (.msi) 64 bit). Is there
> anything apart from this needs to be installed to work with Node?
> In Node window, even if I just type console.log('hello'); and press
> enter, it prints the word 'hello' but in second line it prints 'undefined'.
> Please refer the attached screen shot. What shall be the problem?

Nothing. console.log() prints a string and returns undefined, that's
what you're seeing. Instead of console.log('hello') try 'hello' and
nothing else.
Reply all
Reply to author
Forward
0 new messages