human
I wrote the below code

    pattern = '(\\".*?\\"|\\\'.*?\\\')|(/\\*.*?\\*/|//[^\\r\\n]*\\n)'
    regex = re.compile(pattern, (re.MULTILINE | re.DOTALL))
    def do_replace(match):
        if (match.group(2) is not None):
            return ''
        else:
            return match.group(1)
    return regex.sub(do_replace, code)

What's a good function header?
assistant
#Here's a good function header.

def remove_comments(code):