{
  "index": "1991-B-4",
  "type": "NT",
  "tag": [
    "NT",
    "COMB",
    "ALG"
  ],
  "difficulty": "",
  "question": "Suppose $p$ is an odd prime. Prove that\n\\[\n\\sum_{j=0}^p \\binom{p}{j} \\binom{p+j}{j} \\equiv 2^p + 1\\pmod{p^2}.\n\\]",
  "solution": "Solution 1. The sum \\( \\sum_{j=0}^{p}\\binom{p}{j}\\binom{p+j}{j} \\) is the coefficient of \\( x^{p} \\) in\n\\[\n\\begin{aligned}\n\\sum_{j=0}^{p}\\binom{p}{j}(1+x)^{p+j} & =\\left(\\sum_{j=0}^{p}\\binom{p}{j}(1+x)^{j}\\right)(1+x)^{p} \\\\\n& =((1+x)+1)^{p}(1+x)^{p} \\\\\n& =(2+x)^{p}(1+x)^{p}\n\\end{aligned}\n\\]\nso this coefficient equals\n\\[\n\\sum_{k=0}^{p}\\binom{p}{k}\\binom{p}{p-k} 2^{k}\n\\]\n\nBut \\( p \\) divides \\( \\binom{p}{k} \\) for \\( k \\neq 0 \\). Thus,\n\\[\n\\begin{aligned}\n\\sum_{j=0}^{p}\\binom{p}{j}\\binom{p+j}{p} & \\equiv\\binom{p}{0}\\binom{p}{p} 2^{0}+\\binom{p}{p}\\binom{p}{0} 2^{p} \\\\\n& \\equiv 1+2^{p} \\quad\\left(\\bmod p^{2}\\right)\n\\end{aligned}\n\\]\n\nSolution 2. Modulo \\( p \\), the sets \\( \\{1,2, \\ldots, p-1\\} \\) and \\( \\left\\{1^{-1}, 2^{-1}, \\ldots,(p-1)^{-1}\\right\\} \\) are the same (where the inverses are modulo \\( p \\) ). Thus\n\\[\n\\begin{aligned}\n\\binom{2 p}{p} & =\\frac{p+1}{1} \\cdot \\frac{p+2}{2} \\cdots \\frac{p+(p-1)}{p-1} \\cdot \\frac{2 p}{p} \\\\\n& \\equiv\\left(1^{-1} p+1\\right)\\left(2^{-1} p+1\\right) \\cdots\\left((p-1)^{-1} p+1\\right) \\cdot 2 \\\\\n& \\equiv 2(1 p+1)(2 p+1) \\cdots((p-1) p+1) \\\\\n& \\equiv 2\\left(\\left(\\sum_{k=1}^{p-1} k\\right) p+1\\right) \\\\\n& \\equiv 2 \\quad\\left(\\bmod p^{2}\\right)\n\\end{aligned}\n\\]\n\nAlthough \\( 1^{-1}, \\ldots,(p-1)^{-1} \\) are only defined modulo \\( p \\), they appear in the equations above multiplied by \\( p \\), so the terms make sense modulo \\( p^{2} \\).\n\\[\n\\begin{aligned}\n\\sum_{j=0}^{p}\\binom{p}{j}\\binom{p+j}{j} & =1+\\sum_{j=1}^{p-1}\\binom{p}{j} \\frac{p+1}{1} \\frac{p+2}{2} \\cdots \\frac{p+j}{j}+\\binom{2 p}{p} \\\\\n& \\equiv 1+\\sum_{j=1}^{p-1}\\binom{p}{j}\\left(1^{-1} p+1\\right)\\left(2^{-1} p+1\\right) \\cdots\\left(j^{-1} p+1\\right)+2 \\\\\n& \\equiv 1+\\sum_{j=1}^{p-1}\\binom{p}{j}+2 \\quad\\left(\\text { since } p \\left\\lvert\\,\\binom{ p}{j}\\right. \\text { for } 1 \\leq j \\leq p-1\\right) \\\\\n& \\equiv \\sum_{j=0}^{p}\\binom{p}{j}+1 \\\\\n& \\equiv 2^{p}+1 \\quad\\left(\\bmod p^{2}\\right)\n\\end{aligned}\n\\]",
  "vars": [
    "x",
    "j",
    "k"
  ],
  "params": [
    "p"
  ],
  "sci_consts": [],
  "variants": {
    "descriptive_long": {
      "map": {
        "p": "primeodd",
        "x": "placeholder",
        "j": "iterator",
        "k": "indextwo"
      },
      "question": "Suppose $primeodd$ is an odd prime. Prove that\n\\[\n\\sum_{iterator=0}^{primeodd} \\binom{primeodd}{iterator} \\binom{primeodd+iterator}{iterator} \\equiv 2^{primeodd} + 1\\pmod{primeodd^{2}}.\n\\]",
      "solution": "Solution 1. The sum \\( \\sum_{iterator=0}^{primeodd}\\binom{primeodd}{iterator}\\binom{primeodd+iterator}{iterator} \\) is the coefficient of \\( placeholder^{primeodd} \\) in\n\\[\n\\begin{aligned}\n\\sum_{iterator=0}^{primeodd}\\binom{primeodd}{iterator}(1+placeholder)^{primeodd+iterator} & =\\left(\\sum_{iterator=0}^{primeodd}\\binom{primeodd}{iterator}(1+placeholder)^{iterator}\\right)(1+placeholder)^{primeodd} \\\\\n& =((1+placeholder)+1)^{primeodd}(1+placeholder)^{primeodd} \\\\\n& =(2+placeholder)^{primeodd}(1+placeholder)^{primeodd}\n\\end{aligned}\n\\]\nso this coefficient equals\n\\[\n\\sum_{indextwo=0}^{primeodd}\\binom{primeodd}{indextwo}\\binom{primeodd}{primeodd-indextwo} 2^{indextwo}\n\\]\n\nBut \\( primeodd \\) divides \\( \\binom{primeodd}{indextwo} \\) for \\( indextwo \\neq 0 \\). Thus,\n\\[\n\\begin{aligned}\n\\sum_{iterator=0}^{primeodd}\\binom{primeodd}{iterator}\\binom{primeodd+iterator}{primeodd} & \\equiv\\binom{primeodd}{0}\\binom{primeodd}{primeodd} 2^{0}+\\binom{primeodd}{primeodd}\\binom{primeodd}{0} 2^{primeodd} \\\\\n& \\equiv 1+2^{primeodd} \\quad\\left(\\bmod primeodd^{2}\\right)\n\\end{aligned}\n\\]\n\nSolution 2. Modulo \\( primeodd \\), the sets \\( \\{1,2, \\ldots, primeodd-1\\} \\) and \\( \\left\\{1^{-1}, 2^{-1}, \\ldots,(primeodd-1)^{-1}\\right\\} \\) are the same (where the inverses are modulo \\( primeodd \\) ). Thus\n\\[\n\\begin{aligned}\n\\binom{2\\,primeodd}{primeodd} & =\\frac{primeodd+1}{1} \\cdot \\frac{primeodd+2}{2} \\cdots \\frac{primeodd+(primeodd-1)}{primeodd-1} \\cdot \\frac{2\\,primeodd}{primeodd} \\\\\n& \\equiv\\left(1^{-1} primeodd+1\\right)\\left(2^{-1} primeodd+1\\right) \\cdots\\left((primeodd-1)^{-1} primeodd+1\\right) \\cdot 2 \\\\\n& \\equiv 2(1\\,primeodd+1)(2\\,primeodd+1) \\cdots((primeodd-1)\\,primeodd+1) \\\\\n& \\equiv 2\\left(\\left(\\sum_{indextwo=1}^{primeodd-1} indextwo\\right) primeodd+1\\right) \\\\\n& \\equiv 2 \\quad\\left(\\bmod primeodd^{2}\\right)\n\\end{aligned}\n\\]\n\nAlthough \\( 1^{-1}, \\ldots,(primeodd-1)^{-1} \\) are only defined modulo \\( primeodd \\), they appear in the equations above multiplied by \\( primeodd \\), so the terms make sense modulo \\( primeodd^{2} \\).\n\\[\n\\begin{aligned}\n\\sum_{iterator=0}^{primeodd}\\binom{primeodd}{iterator}\\binom{primeodd+iterator}{iterator} & =1+\\sum_{iterator=1}^{primeodd-1}\\binom{primeodd}{iterator} \\frac{primeodd+1}{1} \\frac{primeodd+2}{2} \\cdots \\frac{primeodd+iterator}{iterator}+\\binom{2\\,primeodd}{primeodd} \\\\\n& \\equiv 1+\\sum_{iterator=1}^{primeodd-1}\\binom{primeodd}{iterator}\\left(1^{-1} primeodd+1\\right)\\left(2^{-1} primeodd+1\\right) \\cdots\\left(iterator^{-1} primeodd+1\\right)+2 \\\\\n& \\equiv 1+\\sum_{iterator=1}^{primeodd-1}\\binom{primeodd}{iterator}+2 \\quad\\left(\\text { since } primeodd \\left\\lvert\\,\\binom{ primeodd}{iterator}\\right.\\text { for } 1 \\leq iterator \\leq primeodd-1\\right) \\\\\n& \\equiv \\sum_{iterator=0}^{primeodd}\\binom{primeodd}{iterator}+1 \\\\\n& \\equiv 2^{primeodd}+1 \\quad\\left(\\bmod primeodd^{2}\\right)\n\\end{aligned}\n\\]\n"
    },
    "descriptive_long_confusing": {
      "map": {
        "x": "lighthouse",
        "j": "rainstorm",
        "k": "sandstone",
        "p": "evergreen"
      },
      "question": "Suppose $evergreen$ is an odd prime. Prove that\n\\[\n\\sum_{rainstorm=0}^{evergreen} \\binom{evergreen}{rainstorm} \\binom{evergreen+rainstorm}{rainstorm} \\equiv 2^{evergreen} + 1\\pmod{evergreen^2}.\n\\]",
      "solution": "Solution 1. The sum \\( \\sum_{rainstorm=0}^{evergreen}\\binom{evergreen}{rainstorm}\\binom{evergreen+rainstorm}{rainstorm} \\) is the coefficient of \\( lighthouse^{evergreen} \\) in\n\\[\n\\begin{aligned}\n\\sum_{rainstorm=0}^{evergreen}\\binom{evergreen}{rainstorm}(1+lighthouse)^{evergreen+rainstorm} & =\\left(\\sum_{rainstorm=0}^{evergreen}\\binom{evergreen}{rainstorm}(1+lighthouse)^{rainstorm}\\right)(1+lighthouse)^{evergreen} \\\\\n& =((1+lighthouse)+1)^{evergreen}(1+lighthouse)^{evergreen} \\\\\n& =(2+lighthouse)^{evergreen}(1+lighthouse)^{evergreen}\n\\end{aligned}\n\\]\nso this coefficient equals\n\\[\n\\sum_{sandstone=0}^{evergreen}\\binom{evergreen}{sandstone}\\binom{evergreen}{evergreen-sandstone} 2^{sandstone}\n\\]\n\nBut \\( evergreen \\) divides \\( \\binom{evergreen}{sandstone} \\) for \\( sandstone \\neq 0 \\). Thus,\n\\[\n\\begin{aligned}\n\\sum_{rainstorm=0}^{evergreen}\\binom{evergreen}{rainstorm}\\binom{evergreen+rainstorm}{evergreen} & \\equiv\\binom{evergreen}{0}\\binom{evergreen}{evergreen} 2^{0}+\\binom{evergreen}{evergreen}\\binom{evergreen}{0} 2^{evergreen} \\\\\n& \\equiv 1+2^{evergreen} \\quad\\left(\\bmod evergreen^{2}\\right)\n\\end{aligned}\n\\]\n\nSolution 2. Modulo \\( evergreen \\), the sets \\( \\{1,2, \\ldots, evergreen-1\\} \\) and \\( \\left\\{1^{-1}, 2^{-1}, \\ldots,(evergreen-1)^{-1}\\right\\} \\) are the same (where the inverses are modulo \\( evergreen \\) ). Thus\n\\[\n\\begin{aligned}\n\\binom{2 evergreen}{evergreen} & =\\frac{evergreen+1}{1} \\cdot \\frac{evergreen+2}{2} \\cdots \\frac{evergreen+(evergreen-1)}{evergreen-1} \\cdot \\frac{2 evergreen}{evergreen} \\\\\n& \\equiv\\left(1^{-1} evergreen+1\\right)\\left(2^{-1} evergreen+1\\right) \\cdots\\left((evergreen-1)^{-1} evergreen+1\\right) \\cdot 2 \\\\\n& \\equiv 2(1 evergreen+1)(2 evergreen+1) \\cdots((evergreen-1) evergreen+1) \\\\\n& \\equiv 2\\left(\\left(\\sum_{sandstone=1}^{evergreen-1} sandstone\\right) evergreen+1\\right) \\\\\n& \\equiv 2 \\quad\\left(\\bmod evergreen^{2}\\right)\n\\end{aligned}\n\\]\n\nAlthough \\( 1^{-1}, \\ldots,(evergreen-1)^{-1} \\) are only defined modulo \\( evergreen \\), they appear in the equations above multiplied by \\( evergreen \\), so the terms make sense modulo \\( evergreen^{2} \\).\n\\[\n\\begin{aligned}\n\\sum_{rainstorm=0}^{evergreen}\\binom{evergreen}{rainstorm}\\binom{evergreen+rainstorm}{rainstorm} & =1+\\sum_{rainstorm=1}^{evergreen-1}\\binom{evergreen}{rainstorm} \\frac{evergreen+1}{1} \\frac{evergreen+2}{2} \\cdots \\frac{evergreen+rainstorm}{rainstorm}+\\binom{2 evergreen}{evergreen} \\\\\n& \\equiv 1+\\sum_{rainstorm=1}^{evergreen-1}\\binom{evergreen}{rainstorm}\\left(1^{-1} evergreen+1\\right)\\left(2^{-1} evergreen+1\\right) \\cdots\\left(rainstorm^{-1} evergreen+1\\right)+2 \\\\\n& \\equiv 1+\\sum_{rainstorm=1}^{evergreen-1}\\binom{evergreen}{rainstorm}+2 \\quad\\left(\\text { since } evergreen \\left\\lvert\\,\\binom{ evergreen}{rainstorm}\\right. \\text { for } 1 \\leq rainstorm \\leq evergreen-1\\right) \\\\\n& \\equiv \\sum_{rainstorm=0}^{evergreen}\\binom{evergreen}{rainstorm}+1 \\\\\n& \\equiv 2^{evergreen}+1 \\quad\\left(\\bmod evergreen^{2}\\right)\n\\end{aligned}\n\\]"
    },
    "descriptive_long_misleading": {
      "map": {
        "x": "immutable",
        "j": "aggregate",
        "k": "totality",
        "p": "composite"
      },
      "question": "Suppose $composite$ is an odd prime. Prove that\n\\[\n\\sum_{aggregate=0}^{composite} \\binom{composite}{aggregate} \\binom{composite+aggregate}{aggregate} \\equiv 2^{composite} + 1\\pmod{composite^{2}}.\n\\]",
      "solution": "Solution 1. The sum \\( \\sum_{aggregate=0}^{composite}\\binom{composite}{aggregate}\\binom{composite+aggregate}{aggregate} \\) is the coefficient of \\( immutable^{composite} \\) in\n\\[\n\\begin{aligned}\n\\sum_{aggregate=0}^{composite}\\binom{composite}{aggregate}(1+immutable)^{composite+aggregate} & =\\left(\\sum_{aggregate=0}^{composite}\\binom{composite}{aggregate}(1+immutable)^{aggregate}\\right)(1+immutable)^{composite} \\\\\n& =((1+immutable)+1)^{composite}(1+immutable)^{composite} \\\\\n& =(2+immutable)^{composite}(1+immutable)^{composite}\n\\end{aligned}\n\\]\nso this coefficient equals\n\\[\n\\sum_{totality=0}^{composite}\\binom{composite}{totality}\\binom{composite}{composite-totality} 2^{totality}\n\\]\n\nBut \\( composite \\) divides \\( \\binom{composite}{totality} \\) for \\( totality \\neq 0 \\). Thus,\n\\[\n\\begin{aligned}\n\\sum_{aggregate=0}^{composite}\\binom{composite}{aggregate}\\binom{composite+aggregate}{composite} & \\equiv\\binom{composite}{0}\\binom{composite}{composite} 2^{0}+\\binom{composite}{composite}\\binom{composite}{0} 2^{composite} \\\\\n& \\equiv 1+2^{composite} \\quad\\left(\\bmod composite^{2}\\right)\n\\end{aligned}\n\\]\n\nSolution 2. Modulo \\( composite \\), the sets \\( \\{1,2, \\ldots, composite-1\\} \\) and \\( \\left\\{1^{-1}, 2^{-1}, \\ldots,(composite-1)^{-1}\\right\\} \\) are the same (where the inverses are modulo \\( composite \\) ). Thus\n\\[\n\\begin{aligned}\n\\binom{2 composite}{composite} & =\\frac{composite+1}{1} \\cdot \\frac{composite+2}{2} \\cdots \\frac{composite+(composite-1)}{composite-1} \\cdot \\frac{2 composite}{composite} \\\\\n& \\equiv\\left(1^{-1} composite+1\\right)\\left(2^{-1} composite+1\\right) \\cdots\\left((composite-1)^{-1} composite+1\\right) \\cdot 2 \\\\\n& \\equiv 2(1 composite+1)(2 composite+1) \\cdots((composite-1) composite+1) \\\\\n& \\equiv 2\\left(\\left(\\sum_{totality=1}^{composite-1} totality\\right) composite+1\\right) \\\\\n& \\equiv 2 \\quad\\left(\\bmod composite^{2}\\right)\n\\end{aligned}\n\\]\n\nAlthough \\( 1^{-1}, \\ldots,(composite-1)^{-1} \\) are only defined modulo \\( composite \\), they appear in the equations above multiplied by \\( composite \\), so the terms make sense modulo \\( composite^{2} \\).\n\\[\n\\begin{aligned}\n\\sum_{aggregate=0}^{composite}\\binom{composite}{aggregate}\\binom{composite+aggregate}{aggregate} & =1+\\sum_{aggregate=1}^{composite-1}\\binom{composite}{aggregate} \\frac{composite+1}{1} \\frac{composite+2}{2} \\cdots \\frac{composite+aggregate}{aggregate}+\\binom{2 composite}{composite} \\\\\n& \\equiv 1+\\sum_{aggregate=1}^{composite-1}\\binom{composite}{aggregate}\\left(1^{-1} composite+1\\right)\\left(2^{-1} composite+1\\right) \\cdots\\left(aggregate^{-1} composite+1\\right)+2 \\\\\n& \\equiv 1+\\sum_{aggregate=1}^{composite-1}\\binom{composite}{aggregate}+2 \\quad\\left(\\text { since } composite \\left\\lvert\\,\\binom{ composite}{aggregate}\\right. \\text { for } 1 \\leq aggregate \\leq composite-1\\right) \\\\\n& \\equiv \\sum_{aggregate=0}^{composite}\\binom{composite}{aggregate}+1 \\\\\n& \\equiv 2^{composite}+1 \\quad\\left(\\bmod composite^{2}\\right)\n\\end{aligned}\n\\]"
    },
    "garbled_string": {
      "map": {
        "x": "qzxwvtnp",
        "j": "mrlgcaue",
        "k": "tpsvznqx",
        "p": "hbdksewq"
      },
      "question": "Suppose $hbdksewq$ is an odd prime. Prove that\n\\[\n\\sum_{mrlgcaue=0}^{hbdksewq} \\binom{hbdksewq}{mrlgcaue} \\binom{hbdksewq+mrlgcaue}{mrlgcaue} \\equiv 2^{hbdksewq} + 1\\pmod{hbdksewq^2}.\n\\]\n",
      "solution": "Solution 1. The sum \\( \\sum_{mrlgcaue=0}^{hbdksewq}\\binom{hbdksewq}{mrlgcaue}\\binom{hbdksewq+mrlgcaue}{mrlgcaue} \\) is the coefficient of \\( qzxwvtnp^{hbdksewq} \\) in\n\\[\n\\begin{aligned}\n\\sum_{mrlgcaue=0}^{hbdksewq}\\binom{hbdksewq}{mrlgcaue}(1+qzxwvtnp)^{hbdksewq+mrlgcaue} & =\\left(\\sum_{mrlgcaue=0}^{hbdksewq}\\binom{hbdksewq}{mrlgcaue}(1+qzxwvtnp)^{mrlgcaue}\\right)(1+qzxwvtnp)^{hbdksewq} \\\\\n& =((1+qzxwvtnp)+1)^{hbdksewq}(1+qzxwvtnp)^{hbdksewq} \\\\\n& =(2+qzxwvtnp)^{hbdksewq}(1+qzxwvtnp)^{hbdksewq}\n\\end{aligned}\n\\]\nso this coefficient equals\n\\[\n\\sum_{tpsvznqx=0}^{hbdksewq}\\binom{hbdksewq}{tpsvznqx}\\binom{hbdksewq}{hbdksewq-tpsvznqx} 2^{tpsvznqx}\n\\]\n\nBut \\( hbdksewq \\) divides \\( \\binom{hbdksewq}{tpsvznqx} \\) for \\( tpsvznqx \\neq 0 \\). Thus,\n\\[\n\\begin{aligned}\n\\sum_{mrlgcaue=0}^{hbdksewq}\\binom{hbdksewq}{mrlgcaue}\\binom{hbdksewq+mrlgcaue}{hbdksewq} & \\equiv\\binom{hbdksewq}{0}\\binom{hbdksewq}{hbdksewq} 2^{0}+\\binom{hbdksewq}{hbdksewq}\\binom{hbdksewq}{0} 2^{hbdksewq} \\\\\n& \\equiv 1+2^{hbdksewq} \\quad\\left(\\bmod hbdksewq^{2}\\right)\n\\end{aligned}\n\\]\n\nSolution 2. Modulo \\( hbdksewq \\), the sets \\( \\{1,2, \\ldots, hbdksewq-1\\} \\) and \\( \\{1^{-1}, 2^{-1}, \\ldots,(hbdksewq-1)^{-1}\\} \\) are the same (where the inverses are modulo \\( hbdksewq \\) ). Thus\n\\[\n\\begin{aligned}\n\\binom{2 hbdksewq}{hbdksewq} & =\\frac{hbdksewq+1}{1} \\cdot \\frac{hbdksewq+2}{2} \\cdots \\frac{hbdksewq+(hbdksewq-1)}{hbdksewq-1} \\cdot \\frac{2 hbdksewq}{hbdksewq} \\\\\n& \\equiv\\left(1^{-1} hbdksewq+1\\right)\\left(2^{-1} hbdksewq+1\\right) \\cdots\\left((hbdksewq-1)^{-1} hbdksewq+1\\right) \\cdot 2 \\\\\n& \\equiv 2(1 hbdksewq+1)(2 hbdksewq+1) \\cdots((hbdksewq-1) hbdksewq+1) \\\\\n& \\equiv 2\\left(\\left(\\sum_{tpsvznqx=1}^{hbdksewq-1} tpsvznqx\\right) hbdksewq+1\\right) \\\\\n& \\equiv 2 \\quad\\left(\\bmod hbdksewq^{2}\\right)\n\\end{aligned}\n\\]\n\nAlthough \\( 1^{-1}, \\ldots,(hbdksewq-1)^{-1} \\) are only defined modulo \\( hbdksewq \\), they appear in the equations above multiplied by \\( hbdksewq \\), so the terms make sense modulo \\( hbdksewq^{2} \\).\n\\[\n\\begin{aligned}\n\\sum_{mrlgcaue=0}^{hbdksewq}\\binom{hbdksewq}{mrlgcaue}\\binom{hbdksewq+mrlgcaue}{mrlgcaue} & =1+\\sum_{mrlgcaue=1}^{hbdksewq-1}\\binom{hbdksewq}{mrlgcaue} \\frac{hbdksewq+1}{1} \\frac{hbdksewq+2}{2} \\cdots \\frac{hbdksewq+mrlgcaue}{mrlgcaue}+\\binom{2 hbdksewq}{hbdksewq} \\\\\n& \\equiv 1+\\sum_{mrlgcaue=1}^{hbdksewq-1}\\binom{hbdksewq}{mrlgcaue}\\left(1^{-1} hbdksewq+1\\right)\\left(2^{-1} hbdksewq+1\\right) \\cdots\\left(mrlgcaue^{-1} hbdksewq+1\\right)+2 \\\\\n& \\equiv 1+\\sum_{mrlgcaue=1}^{hbdksewq-1}\\binom{hbdksewq}{mrlgcaue}+2 \\quad\\left(\\text { since } hbdksewq \\left\\lvert\\,\\binom{ hbdksewq}{mrlgcaue}\\right. \\text { for } 1 \\leq mrlgcaue \\leq hbdksewq-1\\right) \\\\\n& \\equiv \\sum_{mrlgcaue=0}^{hbdksewq}\\binom{hbdksewq}{mrlgcaue}+1 \\\\\n& \\equiv 2^{hbdksewq}+1 \\quad\\left(\\bmod hbdksewq^{2}\\right)\n\\end{aligned}\n\\]\n"
    },
    "kernel_variant": {
      "question": "Let p be an odd prime and define  \n  S(p)=  ∑_{j=0}^{p}  ∑_{k=0}^{p}  2^{\\,j}\\,3^{\\,k}\\,\n            \\binom{p}{j}\\,\\binom{p}{k}\\,\\binom{p+j+k}{\\,p}.  \nProve the super-congruence  \n  S(p)  ≡  8^{\\,p}+9^{\\,p}+12^{\\,p}\\pmod{p^{2}}.\n\n(The congruence is to hold for every odd prime p, including p=3.)\n\n--------------------------------------------------------------------",
      "solution": "Throughout “≡” means congruence in the ring ℤ/p²ℤ; every quantity we\nreduce will first be shown to be an integer.\n\nStep 1.  A generating–function translation  \nFor an indeterminate z we have  \n  binom{p+j+k}{p}=[z^{p}](1+z)^{p+j+k}.  \nTherefore  \n\n  S(p)=∑_{j,k=0}^{p}2^{j}3^{k}\\binom{p}{j}\\binom{p}{k}\n                 [z^{p}](1+z)^{p+j+k}                       (1)\n     =[z^{p}](1+z)^{p}\\Bigl(∑_{j=0}^{p}2^{j}\\binom{p}{j}(1+z)^{j}\\Bigr)\n                       \\Bigl(∑_{k=0}^{p}3^{k}\\binom{p}{k}(1+z)^{k}\\Bigr).\n\nThe two inner sums are binomial expansions:\n\n  ∑_{j=0}^{p}2^{j}\\binom{p}{j}(1+z)^{j}=(3+2z)^{p},  \n  ∑_{k=0}^{p}3^{k}\\binom{p}{k}(1+z)^{k}=(4+3z)^{p}.\n\nHence  \n\n  S(p)= [z^{p}] (1+z)^{p}(3+2z)^{p}(4+3z)^{p}.              (2)\n\nStep 2.  Expanding without introducing denominators  \nWrite each factor in ordinary binomial form:\n\n (3+2z)^{p}=∑_{a=0}^{p}\\binom{p}{a}3^{\\,p-a}(2z)^{a},  \n (4+3z)^{p}=∑_{b=0}^{p}\\binom{p}{b}4^{\\,p-b}(3z)^{b},  \n (1+z)^{p}=∑_{c=0}^{p}\\binom{p}{c}z^{c}.  \n\nCollecting the coefficient of z^{p} gives\n\nS(p)=∑_{a+b+c=p}\\binom{p}{a}\\binom{p}{b}\\binom{p}{c}\n           3^{\\,p-a}4^{\\,p-b}2^{\\,a}3^{\\,b}.                (3)\n\nStep 3.  Isolating a big constant factor  \nFactor 12^{p}=3^{p}4^{p} out of every summand:\n\nS(p)=12^{p}·C(p),  where                            (4)\n\n  C(p)=∑_{a+b+c=p}\\binom{p}{a}\\binom{p}{b}\\binom{p}{c}\n               α^{\\,a}β^{\\,b}, α=2/3, β=3/4.                (5)\n\nBecause 12^{p}·α^{a}β^{b}=3^{\\,p-a+b}2^{\\,a}4^{\\,p-b} is an integer,\nequation (4) shows that S(p) itself is an integer: denominators have\nbeen cleared before any modular reduction.\n\nStep 4.  A p-adic divisibility lemma  \nFor 0<m<p we have v_p( binom{p}{m} ) = 1, while  \nbinom{p}{0}=binom{p}{p}=1.  Consequently the product\nbinom{p}{a}binom{p}{b}binom{p}{c} is divisible by p² whenever at least\ntwo of the indices a,b,c lie in {1,…,p−1}.  \nBecause a+b+c=p, this happens except in the\nfollowing three “edge” cases:\n\n  (p,0,0), (0,p,0), (0,0,p).                             (6)\n\nThus, modulo p²,\n\n  S(p)=12^{p}C(p) ≡ 12^{p}\n       ·( binom{p}{p}binom{p}{0}binom{p}{0}α^{p}\n       + binom{p}{0}binom{p}{p}binom{p}{0}β^{p}\n       + binom{p}{0}binom{p}{0}binom{p}{p}·1 ).         (7)\n\nAll three binomial coefficients occurring in (7) equal 1, so\n\n  S(p) ≡ 12^{p}(α^{p}+β^{p}+1) (mod p²).                 (8)\n\nStep 5.  Converting back to integer powers  \nCompute the three terms in (8):\n\n 12^{p}α^{p}=(12·2/3)^{p}=8^{p},  \n 12^{p}β^{p}=(12·3/4)^{p}=9^{p},  \n 12^{p}·1   =12^{p}.                                       (9)\n\nSubstituting (9) into (8) yields the desired super-congruence  \n\n  S(p) ≡ 8^{p}+9^{p}+12^{p} (mod p²). ∎\n\n--------------------------------------------------------------------",
      "metadata": {
        "replaced_from": "harder_variant",
        "replacement_date": "2025-07-14T19:09:31.720025",
        "was_fixed": false,
        "difficulty_analysis": "1. Double‐sum structure:  The problem now involves a genuinely two-dimensional\n   summation; separating and handling the inner sum demands an additional layer\n   of organisation compared with the single index in the original tasks.\n\n2. Sophisticated generating functions:  Extracting T_j required transforming\n   a binomial sum into a coefficient-of-power problem and manipulating two\n   simultaneous binomial expansions, rather than the lone Vandermonde step of\n   the originals.\n\n3. Careful p-adic bookkeeping:  Keeping only the i=0 and i=p terms in (2)\n   necessitates explicit p-adic divisibility arguments inside a nested\n   expansion.  Such p-adic filtration does not appear in the earlier variants.\n\n4. Re-use and fusion of results:  The solution must recognise and embed the\n   previously derived congruence (the current kernel variant) as a sub-routine,\n   showing inter-dependence of multiple advanced ideas.\n\n5. Exponent arithmetic:  Combining 4^{p} with 2^{p} and 3^{p} to obtain\n   8^{p} and 12^{p} is simple numerically but subtle modulo p², and the\n   justifications rely on multiplicative properties inside the modulus.\n\nAltogether these additions create a problem that is substantially deeper and\nless susceptible to straightforward pattern matching than either the original\nor the current kernel variant."
      }
    },
    "original_kernel_variant": {
      "question": "Let p be an odd prime and define  \n  S(p)=  ∑_{j=0}^{p}  ∑_{k=0}^{p}  2^{\\,j}\\,3^{\\,k}\\,\n            \\binom{p}{j}\\,\\binom{p}{k}\\,\\binom{p+j+k}{\\,p}.  \nProve the super-congruence  \n  S(p)  ≡  8^{\\,p}+9^{\\,p}+12^{\\,p}\\pmod{p^{2}}.\n\n(The congruence is to hold for every odd prime p, including p=3.)\n\n--------------------------------------------------------------------",
      "solution": "Throughout “≡” means congruence in the ring ℤ/p²ℤ; every quantity we\nreduce will first be shown to be an integer.\n\nStep 1.  A generating–function translation  \nFor an indeterminate z we have  \n  binom{p+j+k}{p}=[z^{p}](1+z)^{p+j+k}.  \nTherefore  \n\n  S(p)=∑_{j,k=0}^{p}2^{j}3^{k}\\binom{p}{j}\\binom{p}{k}\n                 [z^{p}](1+z)^{p+j+k}                       (1)\n     =[z^{p}](1+z)^{p}\\Bigl(∑_{j=0}^{p}2^{j}\\binom{p}{j}(1+z)^{j}\\Bigr)\n                       \\Bigl(∑_{k=0}^{p}3^{k}\\binom{p}{k}(1+z)^{k}\\Bigr).\n\nThe two inner sums are binomial expansions:\n\n  ∑_{j=0}^{p}2^{j}\\binom{p}{j}(1+z)^{j}=(3+2z)^{p},  \n  ∑_{k=0}^{p}3^{k}\\binom{p}{k}(1+z)^{k}=(4+3z)^{p}.\n\nHence  \n\n  S(p)= [z^{p}] (1+z)^{p}(3+2z)^{p}(4+3z)^{p}.              (2)\n\nStep 2.  Expanding without introducing denominators  \nWrite each factor in ordinary binomial form:\n\n (3+2z)^{p}=∑_{a=0}^{p}\\binom{p}{a}3^{\\,p-a}(2z)^{a},  \n (4+3z)^{p}=∑_{b=0}^{p}\\binom{p}{b}4^{\\,p-b}(3z)^{b},  \n (1+z)^{p}=∑_{c=0}^{p}\\binom{p}{c}z^{c}.  \n\nCollecting the coefficient of z^{p} gives\n\nS(p)=∑_{a+b+c=p}\\binom{p}{a}\\binom{p}{b}\\binom{p}{c}\n           3^{\\,p-a}4^{\\,p-b}2^{\\,a}3^{\\,b}.                (3)\n\nStep 3.  Isolating a big constant factor  \nFactor 12^{p}=3^{p}4^{p} out of every summand:\n\nS(p)=12^{p}·C(p),  where                            (4)\n\n  C(p)=∑_{a+b+c=p}\\binom{p}{a}\\binom{p}{b}\\binom{p}{c}\n               α^{\\,a}β^{\\,b}, α=2/3, β=3/4.                (5)\n\nBecause 12^{p}·α^{a}β^{b}=3^{\\,p-a+b}2^{\\,a}4^{\\,p-b} is an integer,\nequation (4) shows that S(p) itself is an integer: denominators have\nbeen cleared before any modular reduction.\n\nStep 4.  A p-adic divisibility lemma  \nFor 0<m<p we have v_p( binom{p}{m} ) = 1, while  \nbinom{p}{0}=binom{p}{p}=1.  Consequently the product\nbinom{p}{a}binom{p}{b}binom{p}{c} is divisible by p² whenever at least\ntwo of the indices a,b,c lie in {1,…,p−1}.  \nBecause a+b+c=p, this happens except in the\nfollowing three “edge” cases:\n\n  (p,0,0), (0,p,0), (0,0,p).                             (6)\n\nThus, modulo p²,\n\n  S(p)=12^{p}C(p) ≡ 12^{p}\n       ·( binom{p}{p}binom{p}{0}binom{p}{0}α^{p}\n       + binom{p}{0}binom{p}{p}binom{p}{0}β^{p}\n       + binom{p}{0}binom{p}{0}binom{p}{p}·1 ).         (7)\n\nAll three binomial coefficients occurring in (7) equal 1, so\n\n  S(p) ≡ 12^{p}(α^{p}+β^{p}+1) (mod p²).                 (8)\n\nStep 5.  Converting back to integer powers  \nCompute the three terms in (8):\n\n 12^{p}α^{p}=(12·2/3)^{p}=8^{p},  \n 12^{p}β^{p}=(12·3/4)^{p}=9^{p},  \n 12^{p}·1   =12^{p}.                                       (9)\n\nSubstituting (9) into (8) yields the desired super-congruence  \n\n  S(p) ≡ 8^{p}+9^{p}+12^{p} (mod p²). ∎\n\n--------------------------------------------------------------------",
      "metadata": {
        "replaced_from": "harder_variant",
        "replacement_date": "2025-07-14T01:37:45.560195",
        "was_fixed": false,
        "difficulty_analysis": "1. Double‐sum structure:  The problem now involves a genuinely two-dimensional\n   summation; separating and handling the inner sum demands an additional layer\n   of organisation compared with the single index in the original tasks.\n\n2. Sophisticated generating functions:  Extracting T_j required transforming\n   a binomial sum into a coefficient-of-power problem and manipulating two\n   simultaneous binomial expansions, rather than the lone Vandermonde step of\n   the originals.\n\n3. Careful p-adic bookkeeping:  Keeping only the i=0 and i=p terms in (2)\n   necessitates explicit p-adic divisibility arguments inside a nested\n   expansion.  Such p-adic filtration does not appear in the earlier variants.\n\n4. Re-use and fusion of results:  The solution must recognise and embed the\n   previously derived congruence (the current kernel variant) as a sub-routine,\n   showing inter-dependence of multiple advanced ideas.\n\n5. Exponent arithmetic:  Combining 4^{p} with 2^{p} and 3^{p} to obtain\n   8^{p} and 12^{p} is simple numerically but subtle modulo p², and the\n   justifications rely on multiplicative properties inside the modulus.\n\nAltogether these additions create a problem that is substantially deeper and\nless susceptible to straightforward pattern matching than either the original\nor the current kernel variant."
      }
    }
  },
  "checked": true,
  "problem_type": "proof"
}