przemko icon

Więzy -- kwadrat

przemko | PRO | 06/14/17 10:19:22 AM UTC | 0 ⭐ | 7681 👁️ | Never ⏰ | []
Prolog |

670 B

|

None

|

0 👍

/

0 👎

% kwadrat.pl
 
:- use_module(library(clpfd)).
 
main(Xs) :-
        kwadraty(112,
                 [50,42,37,35,33,29,27,25,24,19,18,17,16,15,11,9,8,7,6,4,2],
                 Xs).
 
kwadraty(D, Ds, Xs) :-
        length(Ds, N),
        D1 is D-1,
        length(Xs, N),
        Xs ins 0..D1,
        length(Ys, N),
        Ys ins 1..D,
        zadania(Xs, Ys, Ds, Zadania),
        cumulative(Zadania, [limit(D)]),
        % SICStus Prolog z opcją global(true) w cumulative/2 8500ms
        labeling([ffc], Xs).
 
zadania([], [], [], []).
zadania([X | L1], [Y | L2], [D | L3], [task(X, D, _, D, _) | L4]) :-
        Y #= X + D,
        zadania(L1, L2, L3, L4).

Comments

  •  icon
    01/01/70 12:00:00 AM UTC
    Plain Text |

    0 B

    |

    👍

    /

    👎

    
        
  • Suikzau icon
    03/31/26 10:06:21 PM UTC
    text |

    0 B

    |

    0 👍

    /

    0 👎

    Best t33n active cpx link daily updates!
     Copy and paste the link in a new browser tab and then hit enter!
     https://crazyporn.@xxx/members/157354/?asgtbndr=1&play=true&spon=adworld&zone=400
     Remove the @ 
  • Zyubi icon
    04/05/26 02:32:14 AM UTC
    text |

    0 B

    |

    0 👍

    /

    0 👎

    Best t33n active cpx link daily updates!
     Copy and paste the link in a new browser tab and then hit enter!
     https://crazyporn.xxx/members/157354/?asgtbndr=1&play=true&spon=adworld&zone=400
  •  icon
    01/01/70 12:00:00 AM UTC
    Plain Text |

    0 B

    |

    👍

    /

    👎