Skip to content
HALOWERK

Game Development Tools

board subtraction grundy table

Return Sprague-Grundy values and losing heap sizes for a supplied finite subtraction game.

POST https://gaming.halowerk.com/v1/board-subtraction-grundy-table

Inputs

Fields of the published input schema
FieldTypeRequiredDescription
movesarrayYes
max_heapintegerYes
Show full input schema
{
  "type": "object",
  "properties": {
    "moves": {
      "type": "array",
      "items": {
        "type": "integer",
        "minimum": 1,
        "maximum": 1000
      },
      "maxItems": 100,
      "minItems": 1
    },
    "max_heap": {
      "type": "integer",
      "minimum": 0,
      "maximum": 10000
    }
  },
  "required": [
    "moves",
    "max_heap"
  ],
  "additionalProperties": false
}

Open original schema

Published input example

{
  "moves": [
    1,
    2
  ],
  "max_heap": 5
}

Result & documentation

Machine-readable documentation of this hub

Source of this page: the published HALOWERK catalog. Updated: 2026-11-19 UTC.

More endpoints in this hub

All endpoints in this hub โ†’