Get Math Help

GET TUTORING NEAR ME!

(800) 434-2582

By submitting the following form, you agree to Club Z!'s Terms of Use and Privacy Policy

    Home / Get Math Help

    Sprague-Grundy Function

    Definition

    Every position of every impartial game has a nim-value, making it equivalent to a nim-heap. To find the nim-value (also called the Sprague-Grundy number), take the mex of the nim-values of the possible moves. The nim-value can also be found by writing the number of counters in each heap in binary, adding corresponding binary digits (mod 2), and interpreting the resulting binary string as a decimal number.

    Back to List | POWERED BY THE WOLFRAM LANGUAGE