  In this paper we provide new quantum algorithms with polynomial speed-up for
a range of problems for which no such results were known, or we improve
previous algorithms. First, we consider the approximation of the frequency
moments $F_k$ of order $k \geq 3$ in the multi-pass streaming model with
updates (turnstile model). We design a $P$-pass quantum streaming algorithm
with memory $M$ satisfying a tradeoff of $P^2 M = \tilde{O}(n^{1-2/k})$,
whereas the best classical algorithm requires $P M = \Theta(n^{1-2/k})$. Then,
we study the problem of estimating the number $m$ of edges and the number $t$
of triangles given query access to an $n$-vertex graph. We describe optimal
quantum algorithms that perform $\tilde{O}(\sqrt{n}/m^{1/4})$ and
$\tilde{O}(\sqrt{n}/t^{1/6} + m^{3/4}/\sqrt{t})$ queries respectively. This is
a quadratic speed-up compared to the classical complexity of these problems.
  For this purpose we develop a new quantum paradigm that we call Quantum
Chebyshev's inequality. Namely we demonstrate that, in a certain model of
quantum sampling, one can approximate with relative error the mean of any
random variable with a number of quantum samples that is linear in the ratio of
the square root of the variance to the mean. Classically the dependency is
quadratic. Our algorithm subsumes a previous result of Montanaro [Mon15]. This
new paradigm is based on a refinement of the Amplitude Estimation algorithm of
Brassard et al. [BHMT02] and of previous quantum algorithms for the mean
estimation problem. We show that this speed-up is optimal, and we identify
another common model of quantum sampling where it cannot be obtained. For our
applications, we also adapt the variable-time amplitude amplification technique
of Ambainis [Amb10] into a variable-time amplitude estimation algorithm.
