Hi,

how about this one:

    basic-magic: [
        [0 8 4]
        [7 3 2]
        [5 1 6]
    ]

    permuts: [[1 2 3] [1 3 2] [2 1 3] [2 3 1] [3 1 2] [3 2 1]]
    id: func [block] [reduce [block/1 block/2]]
    swap: func [block] [reduce [block/2 block/1]]

    magic: copy/deep basic-magic
    foreach rp permuts [
        foreach cp permuts [
            foreach k reduce [:id :swap] [
                repeat r 3 [
                    repeat c 3 [
                        set [pr pc] k reduce [rp/:r cp/:c]
                        poke magic/:pr pc basic-magic/:r/:c
                    ]
                ]
                probe magic
            ]
        ]
    ]

-L

-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.

Reply via email to