def replace_spaces(text: str) -> str:
    """Replaces spaces with '+' in given text.

    :param text: The text to be formatted.
    :returns: Text with spaces replaced with '+'.
    """
    return text.replace(" ", "+")