# st ="hello123!"
# st_upper = st.upper()
# st_lower = st.lower()
# print(st_upper)
# print(st_lower)
# print(st.isalnum())
# print(st.isalpha())
# print(st.isdigit())
s = "Hello world my dear friend"
words = s.split()
print(len(words))
for i in words:
    print(i)