The P-value is an area in the tail of a distribution that tells you the odds of a result happening by chance.
A Q-value is a p-value that has been adjusted for the false discovery rate (FDR). The false discovery rate is the proportion of false positives you can expect to get from a test.