The squares in the following grid are filled with numbers 1 to 9, without repetition, such that the numbers in the squares forming the top and bottom rows add to 20 and 14 respectively and those forming the column to 23. What is the value of A?
1
4
2
6
3
7
4
8