A two-stage model for the appreciation of jokes and cartoons