Alveolar breath was collected from 87 volunteers (HNC and LC patients and healthy controls) in a cross-sectional clinical trial. The discriminative power of a tailor-made Nanoscale Artificial Nose (NA-NOSE) based on an array of five gold nanoparticle sensors was tested, using 62 breath samples. The NA-NOSE signals were analysed to detect statistically significant differences between the sub-populations using (i) principal component analysis with ANOVA and Student's t-test and (ii) support vector machines and cross-validation. The results showed breath testing could clearly distinguish between (i) HNC patients and healthy controls, (ii) LC patients and healthy controls, and (iii) HNC and LC patients. The GC-MS analysis showed statistically significant differences in the chemical composition of the breath of the three groups.