A is an element in the second period, therefore it has two shells K and L. Since A is in the 16 group its outer shells contain 6 electrons. Hence the shell wise electronic configuration of A is 2, 6. Atomic number of A is 8. Subshell electronic configuration of A is 1s² 2s¹ 2p².
Since B is in 3 rd period It has three shells, they are K, L, M. B is in 1st group therefore the outer M shell contains one electron Shell wise electronic configuration of B is 2, 8,1 Atomic number of B is 11. Sub shell wise electronic configuration of Bis 1s² 2s² 2p 3s¹.