If an element has 12 protons and 17 neutrons, how many electrons does it have?

I think the answers twelve but I'm not sure?

Yes, it's twelve!

To determine the number of electrons in an atom, you need to know the atomic number of the element. The atomic number is equal to the number of protons in an atom. In this case, you mentioned that the element has 12 protons.

Since the number of electrons in a neutral atom is equal to the number of protons, this element would indeed have 12 electrons. So your assumption is correct!