There are 6 baskets on the table. Each basket has 2, 0, 9, 8, 12 and 17 apples. Emma chose third, Olivia chose fourth, Matt chose fifth, Liam chose second, John chose first, and Sean chose sixth. How many apples did John and Matt choose in total?