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