When using the definition and properties of the inner product, we get the parallelogram law: $$\:\,\|x+y\|^2 =\: \langle x+y, x+y\rangle= \langle x, x\rangle + \langle x, y\rangle +\langle y, x\rangle +\langle y, y\rangle\,,\\ \|x-y\|^2 =\:\langle x-y, x-y\rangle= \langle x, x\rangle - \langle x, y\rangle -\langle y, x\rangle +\langle y, y\rangle $$
Adding these two expressions:
$$\|x+y\|^2+\|x-y\|^2 \:=\: 2\langle x, x\rangle + 2\langle y, y\rangle
\:=\: 2\|x\|^2+2\|y\|^2$$
as required. But the above does not simplify to Pythagoras' theorem
$\|x+y\|^2=\|x\|^2+\|y\|^2$
if $x$ and $y$ are orthogonal.
How can we get Pythagoras from the parallelogram law?
If you are talking strictly about the parallelogram, when the vector are orthogonal (hence $\langle x, y\rangle=0$, you have
$||x+y||^2= \langle x+y, x+y\rangle= \langle x, x\rangle + \langle x, y\rangle +\langle y, x\rangle +\langle y, y\rangle=\|x\|^2+\|y\|^2$
You can also see it "geometrically", by noticing that this means that when $x$ and $y$ are orthogonal, you have a rectangle, with both diagonals of same length, that is
$||x+y||^2=||x-y||^2$...