First things first, the questions:
Do I just not list this job on my resume?
If it is a recent job then no. This is usually a bad idea.
Not listing jobs on your resume tends to be a bad red flag once someone finds out you've purposefully left out information. You should list jobs that you've done and answer truthfully on why you were discharged.
How do I explain this to future employers
Be frank. In your case you made an "inappropriate joke" and have learnt from it not to do it again. If pressed for details, state that it is embarrassing to talk about unless you've done enough self-reflection and soul searching to be able to do that.
I sure hope the joke was worth it
Secondly; you really could use some self-reflection. Preferably in a setting where your ability of judgement is not clouded.
This might be difficult to grasp, and it might seem unfair to you, but:
- Getting fired for inappropriate jokes that have an enormous social stigma attached to it without any way to back out of it (such a sincere apology), is more of a good reason to get fired rather than bad reason. Not doing a proper apology is also a sign of bad and bullish attitude, lest to mention if it isn't a sociopathic tendency.
- Playing distasteful pranks instead of doing your job is not really professional behavior.
- Some people (like the teacher) genuinely want to do good things in their line of work. Destroying the work of or undermining your co-workers this is always a bad thing.
You're most likely a good person but do take a step back and think it through before you say you were fired for a "bad reason". Was there anything else during your employment that you did that was unprofessional? Write these down and ask yourself why you did it and what could've be done differently.
If you've done enough self-reflection or soul searching, you'll be better prepared on how to explain this mess to your future employers and that you can give confidence that you will work professionally in the future.
Edit:
Just so you know, I've been fired several years ago with slanderous references that would've effectively ended my career. It initially felt unfair at first but since then I've learnt from my mistakes and moved on. At least now I know I've learnt that I should be more careful and mindful of others. :-)
@maple_shaft has an anecdote on how to resolve and own your mistakes.