{
  "schema_version": "1.0",
  "title": "The consensus subsidy calculation",
  "description": "Condensed from the pinned Bitcoin Core implementation; the omitted parameter supplies the 210,000-block interval for mainnet.",
  "type": "code",
  "language": "cpp",
  "code": "CAmount GetBlockSubsidy(int nHeight, const Consensus::Params& params)\n{\n    int halvings = nHeight / params.nSubsidyHalvingInterval;\n    if (halvings >= 64)\n        return 0;\n\n    CAmount nSubsidy = 50 * COIN;\n    nSubsidy >>= halvings;\n    return nSubsidy;\n}"
}
