def snake_to_camel(s: str) -> str:
    """Returns a new str in camelCase, given an str in snake_case.
    Removes all underscore before and after.

    Examples:
        >>> snake_to_camel('snake_to_camel')
        'snakeToCamel'
        >>> snake_to_camel('__snake_to_camel__')
        'snakeToCamel'
        >>> snake_to_camel('alreadyCamel')
        'alreadyCamel'
        >>> snake_to_camel('lonesnake')
        'lonesnake'
    """
    try:
        first, *others = [word for word in s.split('_') if word]
        return first + ''.join(s.title() for s in others)
    except ValueError:
        return s