after awhile, you will have to realize that high school is 100% absolute, complete and total bulllshit, it teaches you next to nothing, and you will forever look at it as 12 wasted, shitty years of your life, it sucks that your school is fucking retarded, but so is everybody elses, and there is nothing any of us can do.
the best things you can do is just grin and bear it, and lay low and try not to get caught doing bad shit.
i know it was a missed assignment in this case though, and that is a fucking retarded reason for detention; maybe you could try to talk to an administrator or someone, and explain to them (in polite, well laid out terms) that having to serve detention for a missed assignment is the stupidest fucking thing ever, and that they need to talk to this instructor and tell them to stop being such a douchebag.