Code a Python program that prints out the longest word in a given sentence.
This is an example sentence with some words.
sentence_string = 'This is an example sentence with some words.'
word_list = sentence_string.split(' ')

longest_word = sorted(word_list, key=len)[-1]

print(longest_word)

# Output
sentence