aboutsummaryrefslogtreecommitdiff
path: root/examples/lister.pd
blob: c9b4ec85825efca66c0c3ba4a692aa2c496501ad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#N canvas 385 348 685 518 10;
#X obj 110 16 lister;
#X text 160 17 - store a list;
#X msg 41 132 bang;
#X text 76 133 outputs a list;
#X text 288 180 sets and outputs a list;
#X text 243 336 creation argument initializes a list;
#X obj 18 381 print;
#X text 291 16 alias;
#X obj 331 16 l;
#X msg 232 315 2 3 5 7 11 prime;
#X obj 41 336 lister 1 2 3 4 5 6 7 ordinal;
#X msg 62 180 1 1 2 3 5 8 13 21 44 fibonacchi;
#X text 64 77 of course \, this is similar to the "pack" object \,
but here we handle list-lenghts dynamically and do not care about type
checking !!!;
#X text 40 434 of course \, this should be named "list" \, but there
already appears to be a "list" object \, though i don't see any use
in it;
#X obj 443 440 list 1 two trois;
#X text 40 473 it seems to store 1 atom only;
#X obj 67 381 list2symbol;
#X symbolatom 67 403 0 0 0 0 output: - -;
#X msg 91 260 one 2 3 four;
#X msg 96 283 list one 2 3 four;
#X text 228 283 works;
#X text 193 260 does NOT work (check console for error);
#X text 353 315 right inlet sets a list without outputting;
#X text 94 222 lists of mixed-type work but if any list starts with
a symbol \, you need to cast it as a list:;
#X msg 77 199 1 two three 4;
#X msg 51 161 7 8 9;
#X text 64 53 similar to:;
#X obj 154 52 float;
#X obj 202 52 int;
#X obj 237 52 symbol;
#X text 497 29 part of zexy;
#X connect 2 0 10 0;
#X connect 9 0 10 1;
#X connect 10 0 6 0;
#X connect 10 0 16 0;
#X connect 11 0 10 0;
#X connect 16 0 17 0;
#X connect 18 0 10 0;
#X connect 19 0 10 0;
#X connect 24 0 10 0;
#X connect 25 0 10 0;