It's undefined behavior. Different platforms/compilers do different things. You'll also get different results extracting such archives with various zip tools if you tried that.

A zip file is sorted alphabetically and since it is assumed that there is only one of each file which one wins in the sorting algorithm is determined by the specifics of the implementation of qsort. This could be mitigated but the fact is the pk3 is broken and it's not clear which of the two (or more) is the canonical lump. I don't know why these mistakes are so common (well I know it's because Slade lets such archives be made, but why don't authors instinctively delete the old/duplicate entries when copy and pasting).