use re builtin method to return binary result