I'm not sure if this will work on you but...
Not everyone has the gift to be funny. But what people don't know that even a nerd can learn how with just some simple basic steps.
Get to know what the person thinks are funny.
This is very useful, take note of those that make the person laugh, preferably those that will never get "old" to them.
Relate a topic to the stuff that makes the person laugh.
When you're in a situation, you have to think quickly on your feet to see if the situation has any connections between the funny stuff.
Example, if you're a boy and talking to your male best friend. Your friend encounters a difficult mathematical question and says, "Why is it so hard?". Knowing that your friend is sort of those "sick minded" people, reply something like, "That's what she said!" or something similar. If your friend is new to the joke, he might have to take awhile to understand the joke. Worst case scenario, he wouldn't laugh or smile at all! Practice makes perfect!
WHAT NOT TO DO
Never ever talk about "dirty" jokes to a girl. Girls don't find it funny.
Try not to prank others. What makes you laugh might not make others laugh.
Never tell jokes that might insult your friend. (E.G. Racist jokes)
What you should do when you made a wrong move
If you told your friend a joke and they didn't smile or laugh, stay quiet for a few seconds and see if they understand the joke. If they don't smile or laugh after a few moments, keep in mind that you should not tell the joke to them anymore.
Find jokes from the Internet or books relating to stuff that the person finds funny.
Try not to tell the jokes over and over again. Keep updated with more jokes!
Here's a good site to try:
http://adf.ly/8kZKV ← Spare 5 seconds.
http://jilljuck.com/jokes ← No adfly.
I may not be funny on JV, but IRL, I'm the class clown.
Good Luck Clowns!