Let $X$ be a random variable, where $X(s)\geq0$ for all $s \in S$, and let $A_k=\{s\in S: A(s)\geq k\}$ Show that $E(X)=\sum^\infty_{k=1} \mathbb{P}(A_k)$.
Pretty stumped on this one. My thought was just to start from the definition of $E(X)$ and try to somehow work $A_k$ into the definition through substitution, but not really seeing a way to do so. Help would be much appreciated!