pattern.match(' '.join(['0f'] * 44))
pattern.match(' '.join(['0f'] * 45))
pattern.match(' '.join(['0f'] * 46))
pattern.match(' '.join(['0f'] * 47))
pattern.match(' '.join(['0f'] * 48))
pattern.match(' '.join(['0f'] * 49))
Regular Expression for a pattern of 45 hex numbers OR 48 hex numbers - Python