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