Given $Y$, suppose that $X|(Y = y)$ is a number picked at random in $[0, y]$. What is $P(X ≤ 1/2)$? 
Question: Let $Y$ be a number picked a random in $[0, 1]$. Given $Y = y$, suppose that $X$ is a random variable such that $X|(Y = y)$ is a number
  picked at random in $[0, y]$. What is $P(X ≤ 1/2)$?

I am really stuck on how to start this one. Well I know that the definition of the conditional probability of two joint random variables is this:
$$f_{X|Y}(x|y) = \frac{f_{XY}(x,y)}{f_Y(y)}$$
but I am not sure how to define the joint probability $f(x,y)$, I think it will involve the uniform distribution? 
 A: Hint/Outline
We are told $Y\sim\text{unif}[0,1]$, which means 
$$f_Y(y) = 1$$
We are also told $X|Y\sim \text{unif}[0,Y]$, hence
$$f_{X|Y}(x|y) = \frac{1}{y}.$$


*

*Notice that we need to find the marginal density of $X$:
$$f_X(x) =  \int_x^1 f_{X,Y}(x,y)\,dy = \int_x^1 f_{X|Y}(x|y)f_Y(y)\,dy = \int_x^1 \frac{1}{y}\cdot 1\,dy=\int_x^1 \frac{1}{y}\,dy$$

*To find $P(X\leq 1/2)$, we have
$$P(X\leq 1/2) = \int_0^{1/2}f_X(x)\,dx.$$
Succinctly,
$$P(X\leq 1/2) = \int_0^{1/2}f_X(x)\,dx = \int_0^{1/2}\int_x^1 f_{X|Y}(x|y)f_Y(y)\,dy\,dx = \int_0^{1/2}\int_x^1 \frac{1}{y}\,dy\,dx.$$
A: You were told the distributions of $Y$, and $X$ given a certain $Y$.
$$\begin{align}Y~\sim~\mathcal U(0;1) \quad\iff & \quad f_Y(y) = \mathbf 1_{y\in(0;1)}\\[1ex]X\mid Y=y ~\sim~\mathcal U(0;y) \quad \iff & \quad f_{X\mid Y}(x\mid y) = \tfrac 1 y~\mathbf 1_{x\in(0;y)}\end{align}$$
So, you know there joint distribution is:
$$\begin{align}f_{X,Y}(x,y) ~ =  & ~ f_{X\mid Y}(x\mid y)~f_Y(y) \\[1ex] ~= & ~ \dfrac 1 y\cdot\mathbf 1_{0\leq x\leq y}\cdot \mathbf 1_{0\leq y\leq 1}\end{align}$$
You can now find $\mathsf P(X\leq 1/2)$.

! $$\begin{align}\mathsf P(X\leq 1/2) ~= & ~ \iint\limits_{x\leq 1/2} f_{X\mid Y}(x\mid y)~f_Y(y)\operatorname d (x,y)
\\[2ex] = & ~ \int_0^{1}\int_0^{\min(y,1/2)} \frac 1 y~\operatorname d x\operatorname d y & = ~ \int_0^{1/2}\int_x^1 \dfrac 1 y~\operatorname d y\operatorname d x\end{align}$$

