用花括号逃避花括号
>>> import re>>> text = '"""!some text'>>> re.findall(r'"{{3}}{symbol}somestext'.format(symbol='!'), text)['"""!some text']但是,
%在这种情况下最好只使用格式设置。

用花括号逃避花括号
>>> import re>>> text = '"""!some text'>>> re.findall(r'"{{3}}{symbol}somestext'.format(symbol='!'), text)['"""!some text']但是,
%在这种情况下最好只使用格式设置。