import re

test = '4706TR Amsterdam'
match =  re.search(r"\b\d{4}[A-Z]{2}\b", test, re.IGNORECASE)
if match:
	print(match.group())