Counting sort initialization of the output array, each take time. Therefore, the time for the whole algorithm is the sum of the times for these steps, . Because it uses arrays of length and , the total space usage of the algorithm is also . For problem instances in which the maximum key value is significantly smaller than the number of items, counting sort can be highly space-efficient, as the only storage it uses other than its input and output arrays is the Count array which uses space . If each item to be sorted is itself an integer, and used as
Blum integer Blum integer In mathematics, a natural number "n" is a Blum integer if "n = p×q" is a semiprime for which "p" and "q" are distinct prime numbers congruent to 3 mod 4. That is, "p" and "q" must be of the form 4"t" + 3, for some integer "t". Integers of this form are referred to as Blum primes. This means that the factors of a Blum integer are Gaussian primes with no imaginary part. The first few Blum integers are Blum integers were named for computer scientist Manuel Blum. All Blum integers are numbers a square-free factor number.