Because it depends on whether you are looking at the phenotype or genotype.
For the 1st example, you are looking at the probability of the recessive trait(which is the phenotype) which is coded for by 2 recessive alleles, so it has a genotype of qq, or q Squared. This means the actual frequency of the q allele is the square root of 0.075 (as each of the 15 snakes has 2 q alleles). So if you are given the phenotypes, square root the probability
But for q2, you are given the actual allele frequencies, so are already given q