Does the sentence use a simile or a metaphor?
Pete swam with ease across the swimming pool, like a dolphin.

 - simile
 - metaphor
Pete swam with ease across the swimming pool, like a dolphin.
The words Pete and dolphin are compared using the word like. So, the sentence uses a simile.