{"size": 366, "ext": "js", "max_stars_repo_path": "time-server.js", "max_stars_repo_name": "AllrightIsHere/learnyounode", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "time-server.js", "max_issues_repo_name": "AllrightIsHere/learnyounode", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "time-server.js", "max_forks_repo_name": "AllrightIsHere/learnyounode", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 22.875, "max_line_length": 73, "alphanum_fraction": 0.6256830601}
const net = require('net');

const port = Number(process.argv[2]);

const server = net.createServer((socket) => {
  const date = new Date();
  const aux = new Date(date.getTime() - date.getTimezoneOffset() * 60000)
    .toISOString()
    .slice(0, 16);
  const result = aux.replace('T', ' ') + '\n';
  socket.write(result);
  socket.end();
});

server.listen(port);
