working check 5, got partially implemented for typecheckign