Consider the following decision problems:
$CONN$= {$〈G,k〉$ ∶ $G$ is undirected graph with at least $k$ connected components}
$E-CONN$= {$〈G,k〉$ ∶ $G$ is undirected graph with exactly $k$ connected components}
I'd like to show this two problem are in $NL$. I Know it's possible to guess a vertex from each connected component and then verify the connectivity of the component (by guessing paths to other vertices). But how can I verify all guessed vertices are different, when it's impossible to hold $k$ vertices on the work tape?