#!/usr/bin/perl -w
#
# Program to remove comments from C/C++ code

while ( $line = <STDIN> ) {
	chomp $line;
	$line =~ s/\/\*[^\/]*\*\///g; # /* Comments * /
	$line =~ s/^\s*\/\/.*//g; # // Comments
	print $line."\n"
}
