Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
2
Task/Ordered-partitions/J/ordered-partitions-1.j
Normal file
2
Task/Ordered-partitions/J/ordered-partitions-1.j
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
require'stats'
|
||||
partitions=: ([,] {L:0 (i.@#@, -. [)&;)/"1@>@,@{@({@comb&.> +/\.)
|
||||
39
Task/Ordered-partitions/J/ordered-partitions-2.j
Normal file
39
Task/Ordered-partitions/J/ordered-partitions-2.j
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
partitions 2 0 2
|
||||
┌───┬┬───┐
|
||||
│0 1││2 3│
|
||||
├───┼┼───┤
|
||||
│0 2││1 3│
|
||||
├───┼┼───┤
|
||||
│0 3││1 2│
|
||||
├───┼┼───┤
|
||||
│1 2││0 3│
|
||||
├───┼┼───┤
|
||||
│1 3││0 2│
|
||||
├───┼┼───┤
|
||||
│2 3││0 1│
|
||||
└───┴┴───┘
|
||||
partitions 1 1 1
|
||||
┌─┬─┬─┐
|
||||
│0│1│2│
|
||||
├─┼─┼─┤
|
||||
│0│2│1│
|
||||
├─┼─┼─┤
|
||||
│1│0│2│
|
||||
├─┼─┼─┤
|
||||
│1│2│0│
|
||||
├─┼─┼─┤
|
||||
│2│0│1│
|
||||
├─┼─┼─┤
|
||||
│2│1│0│
|
||||
└─┴─┴─┘
|
||||
#partitions 2 3 5
|
||||
2520
|
||||
#partitions 5 7 11
|
||||
|out of memory: partitions
|
||||
| # partitions 5 7 11
|
||||
*/ (! +/\.)5 7 11
|
||||
1070845776
|
||||
#partitions 3 5 7
|
||||
360360
|
||||
*/ (! +/\.)3 5 7
|
||||
360360
|
||||
22
Task/Ordered-partitions/J/ordered-partitions-3.j
Normal file
22
Task/Ordered-partitions/J/ordered-partitions-3.j
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
+/\. 2 0 2
|
||||
4 2 2
|
||||
({@comb&.> +/\.) 2 0 2
|
||||
┌─────────────────────────┬──┬─────┐
|
||||
│┌───┬───┬───┬───┬───┬───┐│┌┐│┌───┐│
|
||||
││0 1│0 2│0 3│1 2│1 3│2 3││││││0 1││
|
||||
│└───┴───┴───┴───┴───┴───┘│└┘│└───┘│
|
||||
└─────────────────────────┴──┴─────┘
|
||||
>@,@{@({@comb&.> +/\.) 2 0 2
|
||||
┌───┬┬───┐
|
||||
│0 1││0 1│
|
||||
├───┼┼───┤
|
||||
│0 2││0 1│
|
||||
├───┼┼───┤
|
||||
│0 3││0 1│
|
||||
├───┼┼───┤
|
||||
│1 2││0 1│
|
||||
├───┼┼───┤
|
||||
│1 3││0 1│
|
||||
├───┼┼───┤
|
||||
│2 3││0 1│
|
||||
└───┴┴───┘
|
||||
12
Task/Ordered-partitions/J/ordered-partitions-4.j
Normal file
12
Task/Ordered-partitions/J/ordered-partitions-4.j
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
([,] {L:0 (i.@#@, -. [)&;)/0 1;0 1
|
||||
┌───┬───┐
|
||||
│0 1│2 3│
|
||||
└───┴───┘
|
||||
([,] {L:0 (i.@#@, -. [)&;)/0 1;0 1;0 1
|
||||
┌───┬───┬───┐
|
||||
│0 1│2 3│4 5│
|
||||
└───┴───┴───┘
|
||||
([,] {L:0 (i.@#@, -. [)&;)/0 1;0 1;0 1;0 1
|
||||
┌───┬───┬───┬───┐
|
||||
│0 1│2 3│4 5│6 7│
|
||||
└───┴───┴───┴───┘
|
||||
4
Task/Ordered-partitions/J/ordered-partitions-5.j
Normal file
4
Task/Ordered-partitions/J/ordered-partitions-5.j
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
(<0 1) ([,] {L:0 (i.@#@, -. [)&;)0 1;2 3;4 5
|
||||
┌───┬───┬───┬───┐
|
||||
│0 1│2 3│4 5│6 7│
|
||||
└───┴───┴───┴───┘
|
||||
Loading…
Add table
Add a link
Reference in a new issue