My solution is vanilla as list-abs is a collection of vanilla abstractions for manipulating lists.

On 9/30/24 16:38, claudio nervi wrote:
If you are in Vanille,  the solution in "Vanilla Stile":

#N canvas 766 214 458 396 12;
#N canvas 224 224 330 295 list 0;
#X obj 96 138 list;
#N canvas 192 192 436 397 list 0;
#X msg 193 264 set;
#X msg 266 278 adddollar \$1;
#X obj 132 41 inlet list;
#X obj 93 352 outlet list reverse;
#X obj 170 106 list length;
#X obj 266 194 f;
#X obj 266 224 - 1;
#X obj 284 157 + 1;
#X obj 152 149 f;
#X obj 152 175 until;
#X obj 132 78 t l b l b;
#X msg 93 312 \$10 \$9 \$8 \$7 \$6 \$5 \$4 \$3 \$2 \$1;
#X connect 0 0 11 0;
#X connect 1 0 11 0;
#X connect 2 0 10 0;
#X connect 4 0 7 0;
#X connect 4 0 8 1;
#X connect 5 0 6 0;
#X connect 6 0 5 1;
#X connect 6 0 1 0;
#X connect 7 0 5 1;
#X connect 8 0 9 0;
#X connect 9 0 5 0;
#X connect 10 0 11 0;
#X connect 10 1 8 0;
#X connect 10 2 4 0;
#X connect 10 3 0 0;
#X connect 11 0 3 0;
#X restore 96 105 pd list reverse;
#X obj 96 175 list split 1;
#X obj 96 63 inlet;
#X obj 96 223 outlet;
#X connect 0 0 2 0;
#X connect 1 0 0 0;
#X connect 2 0 4 0;
#X connect 2 1 0 0;
#X connect 3 0 1 0;
#X restore 86 148 pd list separe;
#N canvas 32 32 450 300 select 0;
#X obj 82 80 t f b;
#X obj 162 129 f;
#X obj 162 162 + 1;
#X msg 293 110 0;
#X obj 82 206 f;
#X obj 82 249 outlet;
#X obj 293 38 inlet reset;
#X text 327 112 reset counter;
#X obj 194 38 inlet index;
#X obj 82 38 inlet element;
#X obj 82 163 select;
#X connect 0 0 10 0;
#X connect 0 1 1 0;
#X connect 1 0 2 0;
#X connect 2 0 1 1;
#X connect 2 0 4 1;
#X connect 3 0 1 1;
#X connect 4 0 5 0;
#X connect 6 0 3 0;
#X connect 8 0 10 1;
#X connect 9 0 0 0;
#X connect 10 0 4 0;
#X restore 86 216 pd select index;
#X floatatom 137 184 5 0 0 1 select\ item - - 0;
#X floatatom 86 245 5 0 0 0 - - - 0;
#X msg 63 61 1 3 5 7 9 1000 2 4 8 6;
#X obj 63 107 t l l b;
#N canvas 128 128 393 350 remove 0;
#X obj 66 198 list split;
#X obj 234 89 - 1;
#X obj 99 228 list split 1;
#X obj 66 160 list;
#X msg 66 133 bang;
#X obj 233 114 t b f;
#X obj 234 55 inlet index;
#X obj 151 56 inlet list;
#X obj 139 268 print x2;
#X obj 66 268 print x1;
#X connect 0 0 9 0;
#X connect 0 1 2 0;
#X connect 1 0 5 0;
#X connect 2 1 8 0;
#X connect 3 0 0 0;
#X connect 4 0 3 0;
#X connect 5 0 4 0;
#X connect 5 1 0 1;
#X connect 6 0 1 0;
#X connect 7 0 3 1;
#X restore 63 292 pd remove and split;
#X connect 0 0 1 0;
#X connect 1 0 3 0;
#X connect 2 0 1 1;
#X connect 3 0 6 1;
#X connect 4 0 5 0;
#X connect 5 0 6 0;
#X connect 5 1 0 0;
#X connect 5 2 1 2;

Claudio.

ps.:
¿How can I send a Patch in .pd format to the list?



---
pd-list@lists.iem.at - the Pure Data mailinglist
https://lists.iem.at/hyperkitty/list/pd-list@lists.iem.at/message/TOO4SMA76EDTFHGRIN7XS4UFPMYNHGW4/

To unsubscribe send an email to pd-list-le...@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> https://lists.iem.at/

---
pd-list@lists.iem.at - the Pure Data mailinglist
https://lists.iem.at/hyperkitty/list/pd-list@lists.iem.at/message/RGNXWRF757YCIF3IXVNC4RLICSXIJJK3/

To unsubscribe send an email to pd-list-le...@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> https://lists.iem.at/

Reply via email to