📜  多行字符串中的 python 变量 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:33.790000             🧑  作者: Mango

代码示例1
toname = "Peter"
toemail = "p@tr"
subject = "Hi"
content = f"""From: Fromname 
    To: {toname} <{toemail}>
    MIME-Version: 1.0
    Content-type: text/html
    Subject: {subject}

    This is an e-mail message to be sent in HTML format

    This is HTML message.
    

This is headline.

"""