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