Considering that the decimal number of A multiplied by A is 8, A can only be 9, and B is 2, which is just right.
∴a=9 b=2