University of Illinois issues DMCA takedown for previous years' homework 11 years ago
I'm guessing it is more likely that these repositories were searched for by staff/professors than fully specific code was searched for.
I don't think you can claim that changing code absolves you of copyright issues, it might make it harder to find though.