This is what I have done thus far:
$F(y)=\int_0^1[y'\sin(\pi y)-(y-t)^2]dt=-\frac{1}{\pi}\int_0^1[(\cos(\pi y))\frac{d}{dt}]dt-\int_0^1(y-t)^2dt$
(as $-\frac{1}{\pi}[(\cos(\pi y))\frac{d}{dt}]=-\frac{1}{\pi}\cdot -\pi y'\sin(\pi y)=y'\sin(\pi y)$)
I then used the fundamental theorem of calculus to determine the first part of the integral and determined the second part simply as a polynomial.
$=-\frac{1}{\pi}\cdot\cos(\pi y)-(y^2-y+\frac{1}{3})$
Then, to find the maximum of $F(y)$, I took the derivative and equated it to $0$.
$F'(y)=\sin(\pi y)-2y+1=0$
However, I'm not sure how I should use the above equation to solve for y. Also, did I use the fundamental theorem of calculus correctly above?
*Edit: $y(t)=t$