import random


def parse_rating(line, sep=','):
    """
    Parses a rating line
    Returns: tuple of (random integer, (user_id, profile_id, rating))
    """
    fields = line.strip().split(sep)
    user_id = int(fields[0])  # convert user_id to int
    profile_id = int(fields[1])  # convert profile_id to int
    rating = float(fields[2])  # convert rated_id to int
    return random.randint(1, 10), (user_id, profile_id, rating)