使用Python编写一个函数，该函数接受一个字符串作为参数，并返回字符串中每个单词的首字母大写的新字符串。


"This is a sample sentence."
可以使用Python内置方法`title()`实现该函数：

```python
def capitalize_words(sentence):
    return sentence.title()
```

使用示例：

```python
original_sentence = "This is a sample sentence."
new_sentence = capitalize_words(original_sentence)
print(new_sentence)
# Output: This Is A Sample Sentence.
```