次のように、多くの TeX マークアップを含むファイルがあります。
The fish ate 20\percent more food than the bear.
The fish ate \the\number\percent more food than the bear.
\percent
TeXコードであるテキストを削除して、スペースに置き換えたいと思います。
- マークアップは常に . で始まります
\
。 - マークアップの後には常にスペース、
{
、または別の が続き\
ます。 - は
\
、ファイル内の他の状況では使用されません。
で始まり\
、その後にスペース、{
、または別の が続くこれらのアイテムの外観を削除するにはどうすればよい\
ですか?