That depends on what type of whale and what type of shark. If you take the lightest whale around and the heaviest shark, a shark will be heavier. However, the opposite would mean that a whale is heavier.
Dolphins are sometimes eaten by a specific type of shark. (not sure what shark though) Only because they have no other choice it is a food source so don't go hating sharks because one type of shark eats dolphins and don't hate that type of shark because it eats dolphins