Class 1 will plant =2×1×2=4 trees
Class 2 will plant =2×2×2=8 trees
Class 3 will plant =2×3×2=12 trees
Class 4 will plant =2×4×2=16 trees
Class 5 will plant =2×5×2=20 trees
Similarly for 12 will plant =2×12×2=48 trees
So, 4,8,12,16,20....48 are in A.P.
Here a=4,n=12,l=48
We know that Sn=n2[a+l]
Sn=122[4+48]
Sn=6×52
Sn=312
Hence, 312 trees planted by the students.