It's funny because "just swim across" is a reasonable answer, but the frog that told the joke is annoyed by it because it's not enough of a pun. He thinks the other frog should be cleverer. To the frog that told the joke, this is absurd. He can't comprehend that the other frog isn’t able to think like him. He’s a meta-humor frog, so he is used to using humor as a tool to solve any problem. The other frog is just a regular frog with no meta-humorous abilities.