-q fixed -h and node counting and writing script.