: 33matrix? ( seq -- ? ) 8 swap bounds-check? ; ERROR: not-33matrix seq ; : det ( matrix -- x ) dup 33matrix? not [ not-33matrix ] [ { [ { 0 4 8 } nths product ] [ { 1 5 6 } nths product ] [ { 2 3 7 } nths product + + ] [ { 0 5 7 } nths product ] [ { 1 3 8 } nths product ] [ { 2 4 6 } nths product + + - ] } cleave ] if ;