Another way to say "laughing at a joke is for making friends" is "one can make friends by laughing at jokes"