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