Some new helper functions to count runs in particular deliveries