sort includes; remove spurious continue; fix printf