# Computing epsilon-closure. What does $E(n) \leftarrow \{n\};$ and $E(p)$ mean?

I'm currently reading "Engineering a Compiler" book. In the chapter that explanes computing epsilon-closure there is listed the following algorithm:

But I couldn't understand what does $$E(n)$$ and $$E(p)$$ mean. I know that it has something to do with sets.

For each state $$n \in N$$, we maintain a set of states $$E(n)$$. Eventually, $$E(n)$$ would contain all states reachable from $$n$$ via $$\epsilon$$-transitions.
You can think of $$E$$ as an array of sets. The notation $$E(n)$$ just means the value of $$E$$ at position $$n$$. So $$E(p)$$ is just the value of $$E$$ at position $$p$$.
• It may be useful to note that this notation probably maps into concrete syntax that looks more like E[n] := {n} in many programming languages – Curtis F Aug 23 '19 at 21:04