Show open and closedness of a subset in a metric space Let $(X,d)$ be a metric space and $Y \subset X$. Restrict the metric $d$ on $Y$.    

  
*
  
*Show that $U \cap Y$ is open in Y for all $U \subseteq X$ open in $X$.  
  
*Show that, for any $U_\gamma \subset Y$ open in $Y$ (w.r.t $d$), then $U_\gamma = U \cap Y$, for some $U \subseteq X$ open in $X$ (w.r.t
  $d$)
  

Just learning these, so please don't "jump" through any parts of the proof. What I was thinking so far is  
$B_d(U, r) ≤ B_d(X, r)$ and  $B_d(Y, r) < B_d(X, r)$. For 1 I was thinking then that $B_d(Y, r) ≤ B_d(U, r)$, and showing that both are open? I know the second question is a generalization and answering the first one will naturally lead into the second. 
 A: denote by $d'$ the restricted metric on $Y$ (so for $y_2, y_2 \in Y, d'(y_1, y_2) = d(y_1, y_2)$), and by $B'(y,r)$ the ball wrt $y \in Y$ and $d'$, so $B'(y,r) = \{z \in Y: d'(y,z) < r\}$. These sets generate the metric topology of $d'$.
Then $B'(y,r) = B(y,r) \cap Y$ by definition. $y' \in B'(y,r)$ iff $y' \in Y$ and $d'(y,y)< r$ iff $y' \in Y$ and $d(y,y') < r$ so $y' \in Y \cap B(y,r)$.
Now, $U$ is open in $X$, then $U \cap Y$ is open in $Y$: for let $y \in U \cap Y$. Then ther exists some $r> 0$ such that $B(y,r) \subseteq U$, as $y \in U$ and $U$ is open. But then $B'(y, r) = B(y,r) \cap Y \subseteq U \cap Y$, showing that every $y \in U \cap Y$ is an interior point of $Y$, so $U \cap Y$ is open in $Y$.
On the other hand, if $O \subseteq Y$ is open wrt $d'$, then for every $y \in O$ we pick $r_y > 0$ such that $B'(y,r_y) \subseteq O$.
But then define $U = \cup \{B(y, r_y) : y \in O \}$ is open in $X$ (as a union of open balls) and $U \cap Y = \cup\{ B(y,r_y) \cap Y: y \in O\} = \cup\{B'(y, r_y) \} \subseteq O \subseteq U \cap Y$, as required. 
A: For the first part, let $d_Y$ be the restriction of $d$ on Y. In other words, $Y$ is considered as the subspace of $X$ with this metric $d_Y$. Now for each $x\in U\cap Y$, since then $x\in U$ and $U$ is open (w.r.t to the metric $d$), there exists $r>0$ such that $B_d(x,r)\subset U$. Thus we have $$B_{d_Y}(x,r)=\{y\in Y: d_Y(x,y)<r\}=B_d(x,r)\cap Y\subset U\cap Y.$$ This is true for every $x\in U\cap Y$, hence $U\cap Y$ is open in $Y$ (i.e. open w.r.t the metric $d_Y$).
