Issue #1506: Replace process.stdout.write with console.log

Signed-off-by: Anton Kovalyov <anton@kovalyov.net>