  Quantum protocols commonly require a certain number of quantum resource
states to be available simultaneously. An important class of examples is
quantum network protocols that require a certain number of entangled pairs.
Here, we consider a setting in which a process generates a quantum resource
state with some probability $p$ in each time step, and stores it in a quantum
memory that is subject to time-dependent noise. To maintain sufficient quality
for an application, each resource state is discarded from the memory after $w$
time steps. Let $s$ be the number of desired resource states required by a
protocol. We characterise the probability distribution $X_{(w,s)}$ of the ages
of the quantum resource states, once $s$ states have been generated in a window
$w$. Combined with a time-dependent noise model, the knowledge of this
distribution allows for the calculation of fidelity statistics of the $s$
quantum resources. We also give exact solutions for the first and second
moments of the waiting time $\tau_{(w,s)}$ until $s$ resources are produced
within a window $w$, which provides information about the rate of the protocol.
Since it is difficult to obtain general closed-form expressions for statistical
quantities describing the expected waiting time $\mathbb{E}(\tau_{(w,s)})$ and
the distribution $X_{(w,s)}$, we present two novel results that aid their
computation in certain parameter regimes. The methods presented in this work
can be used to analyse and optimise the execution of quantum protocols.
Specifically, with an example of a Blind Quantum Computing (BQC) protocol, we
illustrate how they may be used to infer $w$ and $p$ to optimise the rate of
successful protocol execution.
