The Jones polynomial of pretzel knots and links