Complete B4, test code added