On sums of independent random variables with unbounded variance, and estimating the average degree in a graph