def likes(list_of_names: list) -> str:
    """
    >>> likes([])
    'no one likes this'
    >>> likes(["Python"])
    'Python likes this'
    >>> likes(["Python", "JavaScript", "SQL"])
    'Python, JavaScript and SQL like this'
    >>> likes(["Python", "JavaScript", "SQL", "JAVA", "PHP", "Ruby"])
    'Python, JavaScript and 4 others like this'
    """

    if len(list_of_names) == 0:
        return "no one likes this"
    if len(list_of_names) == 1:
        return f"{list_of_names[0]} likes this"
    if len(list_of_names) == 2:
        return f"{list_of_names[0]} and {list_of_names[1]} like this"
    if len(list_of_names) == 3:
        return (
            f"{list_of_names[0]}, {list_of_names[1]} and {list_of_names[2]} like this"
        )
    else:
        return f"{list_of_names[0]}, {list_of_names[1]} and {len(list_of_names) - 2} others like this"