adding A and B