If x is the number of drinks each drank last year then 3x+6 is the number of drinks bought last year.
This year 2 bought 3x+6 drinks. They each drank x drinks so they had 3x+6-2x=12 left over. Therefore x=6.
So they drank 6 drinks each.
Last year they bought 24 drinks and drank 18, leaving 6.
This year they bought 24 drinks and drank 12, leaving 12.