On page 134, Weil divisors, example 6.5.2, he said:



> 
> The divisor of $y$ is $2Y$, because
>  $y=0$ implies $z^2=0$, and $z$
>  generate the maximal ideal of the
>  local ring at the generic point of
>  $Y$.
> 
> 
> 


I was stupid and can not figure this out. Can someone give a down to earth computation what is the generic point of $Y$ (Depict it using prime ideals), and what is the local ring at the generic point of $Y$? Further, you are give a closed subset of $X$, cut out by several polynomials, how can you compute the generic point of this subset at once?



A question on generic point and a question on Hartshorne
If $X=Spec(R)$ is an affine scheme (as it is in the example you refer to) and $Y$ is the subscheme defined by a prime ideal $P$, then the generic point of $Y$ is the point $[P]\in Spec(R)$. The local ring at that point is the localization $R\_P$.


In the Hartshorne example, $R={\mathbb C}[x,y,z]/(xy-z^2)$, and $P$ is the ideal $(y,z)$. (You really should have mentioned this in your question). In the ring $R\_P$, the maximal ideal is $(y,z)$, which is the same as $(z)$ (because $x$ is a unit). Because $y$ is a unit times $z^2$, the divisor of $y$ is twice the divisor of $z$. 


