How many possible codons?
Yes, it is.

Gerardo Furtado has already provided a short answer in the comments, but allow me to explain why.

The 4^3 = 64 if all bases can be chosen freely comes down to 4*4*4=64, because you can choose from 4 options for each of the 3 bases.

If you restrict the possibilities of one of the bases, e.g. there are only 2 options for the third base (as in your example), the formula changes to 4*4*2=32, as you can choose from 4 options each for the first 2 bases and from 2 options for the 3rd base.

Edit:
If the 2 'N's from 'NNK' have to be the same, you can choose the first base freely (4 options), the second base is already defined (it has to be the same as the first base, 1 option) and there are 2 options for the 3rd base as described above. Thus, we get 4*1*2=8 possible codons

I hope I could clear this up.