title: sed remove all single line c++ comments, asterisk operator not working
body: <p>I am using sed commands directly in bash script<br>
  I am trying to remove all single line c++ comments<br>
  I have tried this :</p>
  
  <p><code>sed "s/\/\/*//" sample-input.cpp &gt; out.cpp</code></p>
  
  <p>but the above code is not having any difference than the following code on the result :</p>
  
  <p><code>sed "s/\/\//YAHOO/" sample-input.cpp &gt; out.cpp</code></p>
  
  <p>i.e. the two front slashes in my code are going away but the * is having no effect. Help me with this</p>