All else being equal, the number of elements in so many groups is simply a general measure of how well "corrected" a specific lens has been designed.
But because no two lenses are ever equal, this specification is not really useful.
As for zooms, there are so many zoom ranges and aperture sizes provided by so many manufacturers that the #elements isn't a valid comparison.
As for primes, it may be helpful but only when comparing similar lens designs of the same focal lengths (i.e. a 50mm f/1.2 verses a 50mm f/1.4 verses a 50mm f/1.8). But definitely not when comparing a 50mm f/1.8 verses a 28mm f/1.8.
One thing it does do is it generally adds weight to a lens. Although my 300mm f/4 is pretty darn light for having 15 elements (I had to check the #elements).