Define the following subsets of $\mathbb{R}$ and $\mathbb{R}^{2}$ respectively:

$A=\left\{\frac{1}{n}: n \in \mathbb{N}\right\}$

$B=\left\{(x,\frac{1}{x}): x\in\mathbb{R} \smallsetminus \left\{0\right\} \right\}$

I know the first subset, $A$, is neither open nor closed, and the second subset, $B$, is closed.

However, the set $B$ is exactly $A$ but "viewed" in $\mathbb{R}^{2}$, so, why $B$ is neither open nor closed in $\mathbb{R}^{2}$? 

**EDIT:** 

Redefine $B$ as:

$B=\left\{(x,\frac{1}{x}): x \in \mathbb{N}\right\}$. 

$B$ is closed in $\mathbb{R}^{2}$, my question is why intuition fails? ie, $A$ is the projection of $B$ on $\mathbb{R}$ and since $A$ is neither open nor closed in $\mathbb{R}$, I thought $B$ was equally neither open nor closed in $\mathbb{R}^{2}$.