Let the set of size be , and construct a bipartite graph between vertex sets and where is connected to iff . Let be the number of tuples such that is connected to , is connected to , and is connected to , i.e. the number of walks of length 3 in . Suppose that there are edges in , and note that .
First, note that the LHS is equal to . Indeed, given and , there are choices for and choices for . Summing over all pairs gives the result.
Now, summing over all pairs instead, we have that . Now, note that by Holder's inequality we have that
as desired.