I believe the problem here is that software is too unique an entity to the Patent and Copyright offices, and they've never taken the appropriate time to work out what is what.
For instance, maybe an entire package of software can be patented or copywritten, but does that mean someone else's software can't do the same task... or that snippets of code within the patented software can't be used by others? And that is where the real problem lies: Software companies claiming that they have rights to pieces of code, not just entire applications, or that someone else's piece of code is too similar to theirs in function, if not in fact.
In patents, you can patent a device, even if it has other patented devices within it... but you can't patent a piece of a device (say, a screw) if it is not markedly dissimilar to other screws. In copyright law, you can patent a written collection of words, but not individual words. It seems to me, based on legal arguments I've read about, as if software and code challenges are based on the idea that pieces can be patented and/or copywritten, which seems to violate the accepted guidelines of patenting and copyright law.
Perhaps what is needed (and even as I write this, I'm biting my tongue) is a separate entity devoted to software protection, and applying a system that isn't patent, and isn't copyright... but something tailored to the unique issues of software.