I am following Vakil's FOAG, exercise 7.3.H: Let $X\to $Spec $K$ be a finite morphism, prove that $X$ is a finite union of points with the discrete topology.
I am following the guidance there. If we write $X=$Spec $A$ then $A$ is a finite dimensional vector space over $K$. If $A$ was a domain then it is easy to show that it is a field, and so we get that all primes of $A$ are maximal, and hence $X$ consists only of closed points.
The next part should be to prove that $X$ is discrete, and then finiteness would follow from quasicompactness.
My question is why is $X$ discrete? I will be glad for anything you can say about the general problem, but I am looking to understand how it is possible to show discreteness now, before finiteness, say.