Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个文本文件,它包含各种控制字符,包括退格\b和回车\r。例如
\b
\r
100\r101\r102\r103 £\b$\b%
我想“折叠”这些控制字符,让我看到可以在理解这些控制字符的控制台中看到的文本:
103 %
我不知道这叫什么。如果它有名字,请分享它,以便我搜索它。
我想你可以简单地在它上面做一个循环,然后用控制台可以理解的字符替换字符(退格 \b 和回车 \r)