有人可以帮我提供一个正则表达式来删除文件中的多行注释和单行注释吗?
例如:
我真的很感激如果你能帮忙做这件事....提前谢谢。
例如:
" WHOLE "/*...*/" HAS TO BE STRIPED OFF....."
1. /* comment */
2. /* comment1 */ code /* comment2 */ #both /*comment1*/ and /*comment2*/
#has to striped off and rest should
#remain.
3. /*.........
.........
.........
......... */
我真的很感激如果你能帮忙做这件事....提前谢谢。