TITLE: Cohomology of ramified double cover of $\mathbb P^n$ (reference)
QUESTION [17 upvotes]: Let $X\rightarrow \mathbb P^n_{\mathbb C}$ be a double cover ramified over a smooth hypersurface $B$ of degre $2d$. In the case of hypersurfaces of $\mathbb P^n$ one can determine the integral cohomology using Lefschetz hyperlane section theorem and universal coefficients theorem. 

Q. Are there some simple techniques allowing to compute $H^k(X,\mathbb Z)$ for any $k$?

REPLY [5 votes]: Expanding a bit Jason Starr's comment: let $R_X$ (or $R_B$) the jacobian ring of $X$ (resp. $B$). 
Recall that if $X=V(F) \subset w \mathbb{P}(a_0, \ldots, a_n)$, the jacobian ring is defined as $$ R_X := \mathbb{C}[x_0, \ldots, x_n]/(\partial_0(F), \ldots, \partial_n(F)),$$
with the $x_i$ suitably weighted.
From Griffiths result (and its extension to weighted projective hypersurfaces) the cohomology of $X$ can be recovered by looking at some homogeneous slices of $R_X$.
In your situation, if $B=V(f_{2d}) \subset \mathbb{P}^n$, then $X=V(y^2+f_{2d}) \subset w \mathbb{P}(1^{n+1}, d)$. In particular it is trivial to check that $R_X \cong R_B$ and you can find all the cohomology informations for $X$ by looking only at $B$. (note that in general $H^{dim \ X}(X) \neq H^{dim \ B}(B)$, since you will have to look to different homogeneous components of the Jacobian ring)