Tut1

Creating a simple webservervar http = require("http");

var server = http.createServer();

function handleRequest(req, res) {
	res.writeHead(200, {"Content-Type": "text/plain"});
	res.write("Hello World");
	res.end();
}

server.on("request", handleRequest);

server.listen(8080);
//use : cd "directory" to naivgate in the console window to use nodeJs