Inner product on random variables 
Let $(\Omega, \mathscr{F}, P)$ be a probability space and let $L^2$ denote the space of real-valued, discrete random variables with finite variance that map $\Omega$ to a set $Q$.
Define $\langle\cdot,\cdot\rangle:\Omega \to \mathbb R$ such that $\langle X,Y\rangle=E[XY]$
Is $(L^2,\langle\cdot,\cdot\rangle)$ an inner product space ?

$\langle\cdot,\cdot\rangle$ is clearly symmetric and bilinear.
Regarding positive-definiteness, if $\langle X,X\rangle=0$, then $\displaystyle \sum_{x\in X(\Omega)}x^2 P(X=x)=0$
This implies $P(X=0)=1$ and $\forall x\in X(\Omega), x\neq 0 \implies P(X=x)=0$
This doesn't mean $X=0$.
Should I infer $\langle\cdot,\cdot\rangle$ is not an inner product on $L^2$ ?

This is a good observation. The distinction here is that the elements of $L^2$ are not actually functions, but equivalence classes of functions. In this case, the zero element of $L^2$ is
$$\{X\in L^2 : \mathbb P(X=0)=1\}. $$
As $\langle X,X\rangle=0$ implies that $\mathbb P(X=0)=1$, positive-definiteness holds.
