How can hypersurfaces "know" the degree of their defining polynomials? I'm currently trying to learn some complex and projective geometry.
There is one issue bugging me again and again, from different perspectives, and I just can't get my head around it.
One incarnation of my problem:
In the book by Griffiths and Harris, they define the degree of a variety in chapter 1.3.
One of their definitions is:

In case [the variety] $V \subset \mathbb P^n$ is a hypersurface, we have seen that it may be given in terms of homogeneous coordinates $X_0 \dots X_n$ as the locus $V = \big( F(X_0 \dots X_n) = 0 \big)\;$ of a homogeneous polynomial $F$. If $F$ has degree $d$, then [...] $V$ has degree $d$.

A consequence would be for example that the canonical bundle of $V$ is $\mathcal O(d - n - 1) \big|_V$.
My problem is:
As far as I understand it, the object $V$ here is just the hypersurface as a geometrical object (an algebraic variety was defined as the locus of a collection of polynomials and nothing more).
Hence $F$ and $F^2$ would define the same object $V$.
But using $F^2$ instead of $F$ gives us a different degree / a different canonical bundle, which doesn't make sense...
 A: Here is a topological way of recovering the degree. If $V \subset \mathbb{CP}^n$ is a (smooth) hypersurface, then by the Lefschetz hyperplane theorem the map
$$H^2(\mathbb{CP}^n, \mathbb{Z}) \to H^2(V, \mathbb{Z})$$
is injective. The LHS has a distinguished element $\omega$ given by the Chern class of $\mathcal{O}(1)$, and hence so does the RHS. 
Now, the normal bundle to $V$ in $\mathbb{CP}^n$ is a complex line bundle on $V$, and so it also has a Chern class. If $V$ is a hypersurface of degree $d$ then in fact the normal bundle to $V$ is $\mathcal{O}(d) \mid_V$, and so its Chern class is $d \omega$. 
So we find that we can recover the degree using only 1) the Chern class of $\mathcal{O}(1)$ in $H^2(\mathbb{CP}^n, \mathbb{Z})$ and 2) the almost complex structure on the normal bundle to $V$.
A: You are absolutely right: those definitions in the book are rather sloppy!
If you have a homogeneous polynomial $F(X_0,\dots,X_n)$ of degree $d$ you should decompose it into irreducible factors as $F=F_1^{m_1}\dots F_r^{m_r}$ and associate to this decomposition the so-called divisor $$V(F)=m_1V(F_1)+\dots+m_rV(F_r)$$ 
The sets $V(F_i)$ are called the irreducible components of the divisor $V(F)$ and the set $V_{red}(F)=V(F_1)\cup\dots \cup V(F_r)$ is called the support of the divisor $V(F)$.
The degree of the divisor $V(F)$ is of course the degree of $F$ and  $$\operatorname {deg} F=\sum  m_i \operatorname {deg}  F_i$$
Contrary to what one might naïvely think it is not  a good idea to replace $F$ by the product without multiplicities $F_{red}=F_1\dots F_r$.
The reason is that if you consider a family of irreducible polynomials like, say, $$F_t(X_0,\dots,X_n)=X_0^2+t(X^2_1\dots+X_n^2)$$ you want the limit of the $V(F_t)$'s for $t$ tending to zero (strangely, this makes sense!) to be $V(F_0(X_0,\dots,X_n))=V(X^2_0)$ and not $V(X_0)$, in order to obtain a flat pencil of divisors , flatness being a very useful more advanced concept.  
Conclusion
As you very aptly say we must consider hypersurfaces which know the multiplicities in the polynomials which define them: the divisor concept is the key to that knowledge.
In his much more elementary, freely available, online book Algebraic Curves Fulton defines, at the very beginning of chapter 3, a curve exactly in this way: as a divisor.
[As to canonical bundles, I would advise you to only consider them in the case of an irreducible smooth hypersurface  $V(F)$ ($F$ irreducible ) ]
