Simple (and a little dumb)
Intuitionsimple approach that is fastApproachsplit by space,
then split by '-' if you "find" a hyphen
capitalize word function can be replaced by str.title()
bu
# Intuition
<!-- Describe your first thoughts on how to solve this problem. -->
simple approach that is fast
# Approach
<!-- Describe your approach to solving the problem. -->
split by space, 
then split by '-' if you "find" a hyphen
capitalize word function can be replaced by str.title()
but I think this is faster than regex used in title fn
# Complexity
- Time complexity:
<!-- Add your time complexity here, e.g. $$O(n)$$ -->
O(nm) where n is number of rows and m is max num of terms
- Space complexity:
<!-- Add your space complexity here, e.g. $$O(n)$$ -->
O(m) - extra over the dataset
# Code
```pythondata []
import pandas as pd

def capitalize_content(user_content: pd.DataFrame) -> pd.DataFrame:
    def capitalize_word(w:str):
        return str(w[0]).upper() + str(w[1:]).lower()
    def capitalize_text(s:str):
        text = s.split(' ')
        res = list()
        for w in text:
            if w.find('-') == -1:
                res.append(capitalize_word(w))
            else:
                #hyphen word
                h = w.split('-')
                hh = []
                for ww in h:
                    hh.append(capitalize_word(ww))
                res.append('-'.join(hh))
        return ' '.join(res)

        
    user_content['converted_text'] = user_content['content_text'].apply(lambda x : capitalize_text(x))
    
    #print(user_content)
    user_content.rename(columns={'content_text':'original_text'}, inplace=True)
    return user_content
```
['Pandas']