suport 1A0B
suport mAnB
refactor mAnB
support validity check