Add checking input promptly by watilde · Pull Request #43 · npm/init-package-json

I added checking input promptly for fixing npm/npm#4700 and npm/npm#5044. See also related PR npm/promzard#13