C++中移除禁止字符的函数

C++中移除禁止字符的函数

Discuss the way to remove functions that will remove forbidden characters like [ ‘ : ’, ‘ ? ‘, ‘ ’, ‘ / ’, ‘ ’, ‘ | ’, ‘ * ’ ] from a string, for example

Input: str = “ Hello: Welco*me/ to Tu>torials point|. ” Output: “ Hello Welcome to Tutorials point. ” Explanation: Input String contains forbidden characters which got removed and new string has no forbidden characters. Input: str = “ How/ are y*ou doi,ng? ” Output: “ How are you doing ”登录后复制