import re

names = input()

match_pattern = r"\b[A-Z][a-z]+ [A-Z][a-z]+\b"
matches = re.findall(match_pattern, names)

print(" ".join(matches))

dd6acfe993f240383ec3425b720f4ca9225296d7
<mask token>

<mask token>
print(' '.join(matches))

<mask token>
names = input()
match_pattern = '\\b[A-Z][a-z]+ [A-Z][a-z]+\\b'
matches = re.findall(match_pattern, names)
print(' '.join(matches))

import re
names = input()
match_pattern = '\\b[A-Z][a-z]+ [A-Z][a-z]+\\b'
matches = re.findall(match_pattern, names)
print(' '.join(matches))

import re

names = input()

match_pattern = r"\b[A-Z][a-z]+ [A-Z][a-z]+\b"
matches = re.findall(match_pattern, names)

print(" ".join(matches))
