some improvements done from morning in assignment