At what angle the projectile should throw with initial velocity v in order to reach distance d? discard the air resistance, only gravitation acts. So far I got the equations for horizontal and vertical velocity. Can someone point me in right direction?
You're on the right track so far. The next step is to think about what exactly $y(t)$ and $x(t)$ mean.
$y(t)$ tells you the height of the projectile above the ground at any time $t$. Hint: when does the projectile hit the ground?
$x(t)$ tells you the horizontal distance the projectile has traveled after time $t$. Hint: what time should you plug into $x(t)$ so that it gives you the total distance the projectile travels?
After you've considered the above, you need to find a way to solve for $\theta$ in terms of $d$ and $v$.
If you search this site for "projectile" or just Google for something like "trajectory of projectile" you'll find lots of stuff on projectile motion.
In your case the calculation is simpler than calculating the full trajectory since you just need the relationship between $v$, $\theta$ and the range. The way you do this is to use your equation for $y(t)$ to find out how long the projectile is in the air. Then plug the calculated flight time into your equation for $x(t)$ to give the range.
I would use a different equation for the vertical motion. From your classes on Newtonian mechanics you probably remember the equation:
$$ v = u + at $$
where $v$ is the final velocity, $u$ is the initial velocity and $a$ is the acceleration. In your case $u$ = +$V\sin\theta$ and $v$ = -$V\sin\theta$ i.e. the shell starts moving upwards with velocity $V\sin\theta$ reaches the top then falls back and hits the ground with the same velocity but in the opposite direction. That gives you a simpler way to calculate the time of flight $t$ than your quadratic equation for $y(t)$.