Preface. I am reading up on the Chung-Graham-Wilson results on quasi-random graphs, and the description I'm reading is applying an apparently obvious usage of Cauchy-Schwarz that I'm just not seeing. The notes I'm following are here: http://terrytao.wordpress.com/2008/02/15/luca-trevisan-checking-the-quasirandomness-of-graphs-and-hypergraphs/
The problem. Consider a graph $G=(V,E)$, where $|V|=n$, and consider the edge-indicator function $A:V \times V \rightarrow \{0,1\}$ where $A(x,y)=1$ if there is an edge and $0$ otherwise. Now, apparently by Cauchy-Schwarz: $[\sum_{x,y} A(x,y) ]^2 \le n \sum_{x,y,z} A(x,y)A(x,z)$
Tricks I've played with for using C-S: $A(x,y) = A(x,y)*A(x,y)$, and also $A(x,y) = A(x,y)*1$.
I'd very much appreciate it if someone could show me the intermediate steps.