Is $[0,\frac{1}{2})$ open in $[0,1]$ w.r.t usual metric d? Question: 

Consider $[0,1]$ as a metric space, with metric the restriction $d$ on
  $[0,1]$. Show that w.r.t this metric $[0,\frac{1}{2})$ is open in
  $[0,1]$

There is a solution which says:
'$[0,\frac{1}{2})$ = $[0,1]$ $\cap$ $(-\frac{1}{2}, \frac{1}{2})$'
Firstly, could some explain this to me? I understand how it is an intersection, but $(-\frac{1}{2}, \frac{1}{2})$ is not in $[0,1]$ so how can we use it as an open interval?  
My solution was:
$[0,1] \setminus [0,\frac{1}{2})$ = $[\frac{1}{2}, 1]$ which is a closed interval and thus $[0,\frac{1}{2})$ is open. Does this work?
 A: The solution given uses the fact that $[0,1]$ is a subspace of $\mathbb{R}$ and inherits its topology from it. As such, a subset $X \subset [0,1]$ is open iff there exists an open subset $U \subset \mathbb{R}$ such that $U \cap [0,1] = X$. In this case, $U = (-1/2, 1/2)$ is open in $\mathbb{R}$, thus $X = U \cap [0,1] = [0, 1/2)$ is open in $[0,1]$.
Since we're dealing with metric spaces, it's also easier to just notice that $[0,1/2)$ is an open ball in $[0,1]$, with center $0$ and radius $1/2$. So by definition of the topology of $[0,1]$, it is open.
Your solution uses the fact that $[1/2,1]$ is closed in the space $[0,1]$, something that you have not proven. Indeed, you only know that $[1/2, 1]$ is closed in $\mathbb{R}$.
You can again argue that $[1/2,1]$ is the closed ball with center $1$ and radius $1/2$, and is thus closed. But another general fact is that if $E \subset \mathbb{R}$ is closed, then the closed subsets of $E$ are exactly the closed subsets of $\mathbb{R}$ which are contained in $E$. In your case $[0,1]$ is closed, so a subset $F \subset [0,1]$ is closed in $[0,1]$ iff it is closed in $\mathbb{R}$.
A: In my opinion, the correct answer here is that in $([0,1],d)$ the set
$$
B^{[0,1]}_{\frac12}(0) = \{x \in [0,1] \mid d(x,0) < \tfrac12\} = [0,\tfrac12)
$$
is open by definition.
Your answer only works if you have a clear reason why $[\tfrac12, 1]$ is closed in $[0,1]$.
Their answer is a lot like 'my' answer: the set $(-\tfrac12,\tfrac12)$ is equal to $B^{\mathbb R}_{\frac12}(0)$ in $\mathbb R$, and -- as long as $x$ is an element of a subset $X$ of $\mathbb R$ -- we always have the equality
$$
B^{\mathbb R}_{\epsilon}(x) \cap X = B^X_{\epsilon}(x).
$$
A: Definition: A subset $A$ of the metric space $([0,1],d)$ is open in $([0,1],d)$ if there is an open subset $B$ of the metric space $(\mathbb R,d)$ such that
$A=[0,1] \cap B$
In your question: $A=[0,\frac{1}{2})$ and $B=(-\frac{1}{2}, \frac{1}{2})$
