Mbpp/287

⚠️ 仅 Base 通过 Base: PASS Plus: FAIL
测试评估
指标结果
Base 测试PASS
Plus 测试FAIL
代码长度346 字符
模型生成的代码 (346 字符)
def square_Sum(n: int) -> int:
    """
    Returns the sum of squares of the first n even natural numbers.
    
    The i-th even natural number is 2i, so we compute sum_{i=1}^n (2i)^2.
    Using the formula: 4 * sum_{i=1}^n i^2 = 4 * n(n+1)(2n+1)/6.
    """
    # Mathematical formula for efficiency
    return 4 * n * (n + 1) * (2 * n + 1) // 6
Base 失败测试用例
  • 无失败测试
Plus 失败测试用例
  • [1000000]