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