import hashlib


def md5(data):
    """ Return md5 hash of a string 
        >>> md5('this is a test')
        '54b0c58c7ce9f2a8b551351102ee0938'
    """
    # Seems to be java-ish levels of complexity here ...
    return hashlib.md5(data.encode()).hexdigest()