← All Duels

claude-opus-4-5-20251101_vs_deepseek-reasoner_20260124_082844.jsonl — 10 puzzles

claude-opus-4-5-20251101
-1
vs
deepseek-reasoner
-1
#1 Solved
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    n, p = x, []
    d = 2
    while d * d <= n:
        while n % d == 0:
            p.append(d)
            n //= d
        d += 1
    if n > 1:
        p.append(n)
    s = sum(i * j for i, j in enumerate(sorted(p)))
    return len(p) == 4 and len(set(p)) == 4 and s == 174 and x % 997 == 565
351509
351509
Proposer: claude-opus-4-5-20251101 Solver: deepseek-reasoner
0 vs 0
#2 Solved
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    # perfect square?
    if int(x ** 0.5) ** 2 != x:
        return False
    # sum of digits prime?
    s = sum(int(d) for d in str(x))
    if s < 2:
        return False
    for i in range(2, int(s ** 0.5) + 1):
        if s % i == 0:
            return False
    # reverse prime?
    rx = int(str(x)[::-1])
    if rx < 2:
        return False
    for i in range(2, int(rx ** 0.5) + 1):
        if rx % i == 0:
            return False
    # exactly three 1's in binary?
    if bin(x).count('1') != 3:
        return False
    # modulo condition
    if x % 123 != 46:
        return False
    return True
784
784
Proposer: deepseek-reasoner Solver: claude-opus-4-5-20251101
0 vs 0
#3 Solved
def mystery(x):
    if not isinstance(x, int) or x < 0:
        return False
    
    b = bin(x)[2:]
    
    # Exactly 20 bits
    if len(b) != 20:
        return False
    
    # Exactly 10 ones
    if b.count('1') != 10:
        return False
    
    # Binary palindrome
    if b != b[::-1]:
        return False
    
    # Decimal digit sum constraint
    digit_sum = sum(int(d) for d in str(x))
    if digit_sum != 24:
        return False
    
    # Specific modular constraint
    if x % 9973 != 2067:
        return False
    
    return True
540609
540609
Proposer: claude-opus-4-5-20251101 Solver: deepseek-reasoner
0 vs 0
#4 Sample Solution Wrong
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    
    # Modulo condition: last three digits 729
    if x % 1000 != 729:
        return False
    
    # Harshad number: divisible by sum of digits
    digit_sum = sum(int(d) for d in str(x))
    if digit_sum == 0 or x % digit_sum != 0:
        return False
    
    # Binary weight: exactly 6 ones
    if bin(x).count('1') != 6:
        return False
    
    # Check sum of two cubes in two distinct ways
    max_a = int(round(x ** (1/3))) + 1
    pairs = []
    for a in range(1, max_a):
        a3 = a * a * a
        if a3 > x:
            break
        for b in range(a, max_a):
            b3 = b * b * b
            s = a3 + b3
            if s > x:
                break
            if s == x:
                pairs.append((a, b))
                if len(pairs) >= 2:
                    break
        if len(pairs) >= 2:
            break
    if len(pairs) < 2:
        return False
    
    # Check Carmichael number using Korselt's criterion
    # Factor x by trial division
    n = x
    factors = []
    d = 2
    while d * d <= n:
        while n % d == 0:
            factors.append(d)
            n //= d
        d += 1 if d == 2 else 2
    if n > 1:
        factors.append(n)
    
    # Must be composite
    if len(factors) == 1:
        return False
    
    # Must be squarefree
    if len(set(factors)) != len(factors):
        return False
    
    # For each prime factor p, p-1 divides x-1
    for p in set(factors):
        if (x - 1) % (p - 1) != 0:
            return False
    
    return True
1729
Proposer: deepseek-reasoner Solver: claude-opus-4-5-20251101
0 vs -1
#5 Solved
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    
    s = str(x)
    if len(s) != 8:
        return False
    
    digits = [int(d) for d in s]
    if 0 in digits:
        return False
    
    first_half = int(s[:4])
    r1 = int(first_half ** 0.5 + 0.5)
    if r1 * r1 != first_half:
        return False
    
    last_half = int(s[4:])
    r2 = int(last_half ** 0.5 + 0.5)
    if r2 * r2 != last_half:
        return False
    
    if r1 + r2 != 117 or r1 * r2 != 2916:
        return False
    
    if x % 97 != 86:
        return False
    
    if digits[3] != digits[4]:
        return False
    
    return True
12966561
12966561
Proposer: claude-opus-4-5-20251101 Solver: deepseek-reasoner
0 vs -1
#6 Solved
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    
    s = str(x)
    # 7-digit palindrome
    if len(s) != 7:
        return False
    if s != s[::-1]:
        return False
    
    # exactly 4 distinct digits
    if len(set(s)) != 4:
        return False
    
    # perfect square
    r = int(x ** 0.5)
    if r * r != x:
        return False
    
    # square root is also a palindrome
    rs = str(r)
    if rs != rs[::-1]:
        return False
    
    # sum of digits of x is a perfect square
    sx = sum(int(d) for d in s)
    if int(sx ** 0.5) ** 2 != sx:
        return False
    
    # sum of digits of square root is a perfect square
    sr = sum(int(d) for d in rs)
    if int(sr ** 0.5) ** 2 != sr:
        return False
    
    # binary weight exactly 10
    if bin(x).count('1') != 10:
        return False
    
    # specific modular condition
    if x % 997 != 35:
        return False
    
    return True
1234321
1234321
Proposer: deepseek-reasoner Solver: claude-opus-4-5-20251101
0 vs -1
#7 Solved
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    
    n = x
    factors = []
    d = 2
    while d * d <= n:
        while n % d == 0:
            factors.append(d)
            n //= d
        d += 1
    if n > 1:
        factors.append(n)
    
    if len(factors) != 6:
        return False
    
    if len(set(factors)) != 3:
        return False
    
    from collections import Counter
    counts = Counter(factors)
    if not all(c == 2 for c in counts.values()):
        return False
    
    if sum(set(factors)) != 100:
        return False
    
    if x % 9973 != 2426:
        return False
    
    return True
17255716
17255716
Proposer: claude-opus-4-5-20251101 Solver: deepseek-reasoner
0 vs -1
#8 Solved
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    # 8 digits
    if x < 10_000_000 or x > 99_999_999:
        return False
    s = str(x)
    if '0' in s:
        return False
    # Decompose into YYYYMMDD
    year = int(s[:4])
    month = int(s[4:6])
    day = int(s[6:8])
    # Specific month and day
    if month != 11 or day != 13:
        return False
    # Year must be prime
    if year < 2:
        return False
    for i in range(2, int(year**0.5) + 1):
        if year % i == 0:
            return False
    # Sum of digits of year must be prime
    year_digit_sum = sum(int(d) for d in str(year))
    if year_digit_sum < 2:
        return False
    for i in range(2, int(year_digit_sum**0.5) + 1):
        if year_digit_sum % i == 0:
            return False
    # Check that the date is a Friday using Zeller's congruence
    # weekday: 0=Saturday, 1=Sunday, ..., 6=Friday
    def weekday(y, m, d):
        if m < 3:
            m += 12
            y -= 1
        K = y % 100
        J = y // 100
        h = (d + (13*(m+1))//5 + K + K//4 + J//4 - 2*J) % 7
        return h
    if weekday(year, month, day) != 6:
        return False
    # Product of all digits must be a perfect cube
    prod = 1
    for ch in s:
        prod *= int(ch)
    # perfect cube check
    root = round(prod ** (1/3))
    if root**3 != prod:
        return False
    # Specific modular condition
    if x % 997 != 374:
        return False
    return True
91811113
91811113
Proposer: deepseek-reasoner Solver: claude-opus-4-5-20251101
0 vs -1
#9 Sample Solution Wrong
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    
    s = str(x)
    
    if len(s) != 12:
        return False
    
    parts = [int(s[i:i+3]) for i in range(0, 12, 3)]
    
    cubes = [1, 8, 27, 64, 125, 216, 343, 512, 729]
    if any(p not in cubes for p in parts):
        return False
    
    cube_to_root = {1:1, 8:2, 27:3, 64:4, 125:5, 216:6, 343:7, 512:8, 729:9}
    digits = [cube_to_root[p] for p in parts]
    
    if len(set(digits)) != 4:
        return False
    
    if sum(digits) != 20:
        return False
    
    prod = 1
    for d in digits:
        prod *= d
    root = int(prod ** 0.5 + 0.5)
    if root * root != prod:
        return False
    
    if x % 9973 != 3498:
        return False
    
    return True
729008027216
Proposer: claude-opus-4-5-20251101 Solver: deepseek-reasoner
-1 vs -1
#10 Solved
def mystery(x):
    if not isinstance(x, int) or x <= 0:
        return False
    s = str(x)
    if s != s[::-1]:
        return False
    # perfect square
    r = int(x ** 0.5 + 0.5)
    if r * r != x:
        return False
    # square root palindrome
    rs = str(r)
    if rs != rs[::-1]:
        return False
    # sum of digits perfect square
    sd = sum(int(d) for d in s)
    if int(sd ** 0.5 + 0.5) ** 2 != sd:
        return False
    # product of digits perfect square
    prod = 1
    for d in s:
        prod *= int(d)
    if int(prod ** 0.5 + 0.5) ** 2 != prod:
        return False
    # binary weight exactly 10
    if bin(x).count('1') != 10:
        return False
    # modular condition
    if x % 997 != 35:
        return False
    return True
1234321
1234321
Proposer: deepseek-reasoner Solver: claude-opus-4-5-20251101
-1 vs -1