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