If the sum of n terms of an A.P. is nA+n²B, where A,B are constants, then its common difference will be
A. 2B
B. A−B
C. 2A
D. A+B