
    In an adaptive learning system, write a function that validates if a student's ID number follows the special pattern where it equals one less than double its reverse digits, which determines their personalized learning track placement. For example, if a student's ID is 36, its reverse is 63, and the function should check if 36 equals (2 * 63 - 1).
    

    
def rev(num):
    rev_num = 0
    while num > 0:
        rev_num = rev_num * 10 + num % 10
        num = num // 10
    return rev_num

def check(n):
    """
    In an adaptive learning system, write a function that validates if a student's ID number follows the special pattern where it equals one less than double its reverse digits, which determines their personalized learning track placement. For example, if a student's ID is 36, its reverse is 63, and the function should check if 36 equals (2 * 63 - 1).
    

    """
def rev(num):
    rev_num = 0
    while num > 0:
        rev_num = rev_num * 10 + num % 10
        num = num // 10
    return rev_num

def check(n):
    """
    In an adaptive learning system, write a function that validates if a student's ID number follows the special pattern where it equals one less than double its reverse digits, which determines their personalized learning track placement. For example, if a student's ID is 36, its reverse is 63, and the function should check if 36 equals (2 * 63 - 1).
    

    """
    return 2 * rev(n) == n + 1