Here, first term of AP,` a = 5`
Last termof AP,`l = 45`
Sum of AP, `S = 400`
We know,
`S = n/2(a+l) =>400 = n/2(45+5)=>n = 8**2 = 16`
So, number of terms is `16`.
As, last term is `45`, we can write,
`5+(16-1)d = 45`
`d = 40/15 = 8/3`
So, common difference is `8/3`.