« first day (1739 days earlier)      last day (1209 days later) » 

00:08
yeah
it's a little bit slow because it has to make so many nested vectors, a flatter approach seems to be a lot faster
≢{((~x)\2-⍨/⍸m,1)+(x←0 1⍴⍨2×+/m)\⍵/⍨m←1,2≠/⍵}⍣40⊢⍎¨'1321131112'
I'm sure there's something better
also you can shave off the last iteration because the length is twice the sum of the mask
2×1++/2≠/{((~x)\2-⍨/⍸m,1)+(x←0 1⍴⍨2×+/m)\⍵/⍨m←1,2≠/⍵}⍣49⊢⍎¨'1321131112' is the fastest I've got for part 2
ofc it's much longer and uglier sooo doesn't matter too much
 
3 hours later…
03:00
⊢∘≢⌸Y and {≢⍵}⌸Y, are they the same?
 
10 hours later…
12:43
@LdBeth yes
 
4 hours later…
16:21
@Adám do you know why ⎕WC doesn't return an object? Or anything about the design of it?
 
1 hour later…
 
6 hours later…
23:37
@rak1507 You mean, why does it return the fully qualified name instead of a ref?
if that's what an object is? the 'name'⎕WC'foobar' design seems a bit strange, why not name←⎕WC'foobar'?
@Adám ah, no, the return value is strange, but I was more wondering why it does all this string based stuff (socket does too... I'm sensing a pattern)
it makes it very hard to write functional-esque code
Because it is old, from before Dyalog APL had refs. If you want a more modern behaviour, just use ⎕NEW
for example, in a dfn, I need to do _←'a'⎕WC... rather than a←⎕WC...
@Adám hm, fair enough
Or simply a←⎕NEW⊂'Form'
ok, interesting
oh, also, is there any way to set the number of pixels rather than proportion of screen size in a form? I want to set something like 500 by 500 rather than calculating that from screen size (also is there a way of accessing that programmatically within APL?)
23:46
@rak1507 Look at Coord and APLcart. (I'll add "size" to that.)
great, thank you
there should really be one big page with some table of all the possible values and stuff, information seems quite hard to find (aplcart obviously makes this significantly nicer but I don't bother checking it with most utilities/libraries related stuff)
aplcart does have stuff for ⎕WC but then you have to look at each individually to try and find what you need
or google it and find information from version 12 :P

« first day (1739 days earlier)      last day (1209 days later) »