We have dealt with double slash comments in The Resurrection Competition. How about dealing with all kinds of comments today?
Your task is extremely easy, delete all comments in given codes and keep the format.
A common cpp source code. The characters in each line are less than 1000, there are not more than 100 lines. The invisible characters in the input are only '\t', ' ', ,'\n', '\r'.
The code without comments. If a line only has comments and invisible characters, delete this line. (But if the line just has invisible characters, don’t delete it)
See more details in sample.