« first day (1778 days earlier)      last day (866 days later) » 
00:00 - 19:0019:00 - 00:00

7:00 PM
@PaulMansour Sure, and Key isn't O(n²), which is its whole raison d'être. Obviously, this functions shouldn't be implemented as I did.
 
Ok, I missed the point of the exercise.
 
The whole point here is to move out of Key so you don't end up computing it twice (once inside Key and once to get the uniques) and so you can supply your own "alphabet".
There we go: {⍺←∪⍵ ⋄ ⍺ (⊂⍤⍸≡⍤¯1)⍤¯1 88⊢⍵}
Rank FTW.
 
Adám, what was the 3rd monadic operator I was missing? I added ⌸ and &
Rank FTW indeed
Oh, I think it was bracket-axis
 
@Adám Got it. I think have code that does exactly that - probably 20 years old!
 
@FawnLocke ∘. :-/
 
7:10 PM
∘. feels wrong as a monadic operator...
 
Hence my ":-/"
But if you put it in the table as ∘.f it doesn't look too out of place.
 
I'd rather say that . is a hyperator. But that's also :-/
 
I'd want to replace it with a more sensible syntax (e.g. the free f\) but Roger says to "simply" use f¨⍤0 99
 
Yeah.
 
. is way too overloaded anyway.
@FawnLocke What does "Yeah" refer to?
 
7:14 PM
Replacing it with a more sensible syntax
I like f¨⍤0 99 but it's not very beginner friendly
 
Using rank does make you think if you really need that ¨ though.
Whereas ∘. always has it.
 
That's true
 
@PaulMansour I think someone suggested < and > for box and unbox.
 
@Adám I assume that differs somehow from enclose and disclose? I don't think i know what box/unbox means.
 
@PaulMansour The SHARP APL or J definition. Boxed arrays act as simple scalars. (<'abc') = (<'abc'),(<'de') would give 1 0.
This is a generalisation of a string data type.
 
7:29 PM
@Adám Ah, that was my next question.
 
tryapl is down (for me) btw.
 
Would that be required for k-style dictionaries?
 
A dictionary type :-)
 
Everything look correct?
 
@FawnLocke Thanks, rebooted.
 
7:31 PM
^^
 
@FawnLocke No, outer product is dyadic only, not monadic only.
 
Thanks
 
I'd call Monadic Key "Index Key".
 
Done :)
 
Looks good otherwise. Now for those dyadic operators!
Oh, the legend doesn't need , g
Unless you want to write outer product as ∘.g
 
7:35 PM
Indeed, appreciate the help :) And true. Would I just write f.f, f∘f then?
Kinda ugly. And ∘.g might be a good clarification
 
@Adám I think I meant symbol data type. Would adding symbol type in APL require box and unbox primitives?
 
@FawnLocke No no, the legend as it stands now is under the Monadic Operators heading. I assumed you intended a separate legend for the dyadic ones.
 
Ah. I thought it might be more space conservative to define a single legend. Is that confusing? I could define it above the headers - or two separate ones
 
@PaulMansour We could add a symbol type (in fact, we already have one – it is just hidden, though a bug in old versions allowed you to access it…), but it isn't necessary for dictionaries.
 
@PaulMansour high rank messes with unifying dictionary and array accessing though
 
7:42 PM
We'd need a way to convert charvecs to/from symbols, of course, but it doesn't have to be a set of primitives.
@dzaima How so?
You can pretty much implement a dictionary type using a keyed default property of a class. Only real difference is that it ends up having reference semantics, afaict.
 
@Adám Array keys are lists of integers. Dictionary keys are arbitrary objects. But indexing functions assume keys are always lists, e.g. x≡⍬⌷x but you can't have that if is a valid key
 
Ah, right. Then you'd want to box
 
and that's incredibly ugly.
 
You similarly need to enclose keys for a keyed property.
 
so it's already ugly
 
7:50 PM
Yup.
 
8:12 PM
Hi Adam, pursuant to my last question about Conga, I'm proxying HTTP POST requests to the Conga server. I've tried controlling for all variables and I've duplicated the setup on the server on my local machine as much as possible, and the proxy system works on the local machine but not on the server.
I know the POST requests are being received on the server side because the APL interpreter prints the expected output, but rather than returning the expected output for the POST request that error appears
 
8:46 PM
@phantomics What mode are you using Conga in?
 
@Nick Hej. Er du interesseret i APL?
 
@Brian How do I check that? The Conga server is part of a larger workspace I'm using, I didn't write the Conga config
 
@phantomics it would be at the call to i.Srv
 
I see this call: DRC.Srv''IPHOME(PORT[I])'Raw' 10000
I take it the mode is 'Raw'?
 
@phantomics that's correct... Conga maintains a hierarchy of objects, the root ('.'), the server (SRV00000000), and connections to the server (SRV00000000.CONxxxxxxxx). The invalid object means that the connection object doesn't exist. So, we need to figure out 1) did it ever exist, and if so, 2) what happened to it.
Using raw mode to process HTTP requests is less than optimal. HTTP mode has been around since Conga v3.0. But it sounds like someone else wrote the server component?
 
9:03 PM
@Brian Ok, I've noticed that the POST requests take a very long time before the error message appears, they do nothing for like 5 minutes, then the interpreter prints the error and at the web browser's end a 502 error is returned
@Brian Correct, would it make sense to swap 'Http' for 'Raw'?
 
It's not as simple as just swapping 'http' for 'raw'...
But writing an HTTP server in Conga (using HTTP mode) is really easy.
@phantomics So, now things make a bit more sense... to process an HTTP request in raw mode you need to, receive data until you get CRLFCRLF (then you've got the headers)... then parse the headers for content-length... then listen for that many bytes and that's your payload. There's a lot of work being done, and it's easy to miss nuances, like a 0 length payload.
Jarvis has an HTTP server at its core, and there are object-oriented samples of HttpServers in github.com/Dyalog/samples-conga/tree/master/HttpServers
 
Ok, thing is, I know the data is being received by the server. The interpreter prints some data indicating that it has received and processed the request. The problem seems to be with returning.
 
@phantomics I'd really need to see the code to be able to tell what's going on... otherwise I'm just guessing at possible causes... there are lots scenarios that could be happening...
@phantomics I suspect you're not getting the entire HTTP message, and the connection is timing out and closing during the 5 minutes it's waiting and when it tries to send a response, the connection is already gone
 
9:22 PM
@Brian That's a good hypothesis, could the error be happening because the client has dropped the connection due to timeout?
This error: Unable to Send for client SRV00000000.CON00000000 (1008): ERR_INVALID_OBJECT
 
@phantomics That's one plausible scenario
 
I'll see what I can do to show you code
 
@phantomics Thanks... it would be easiest to send it via email (brian@dyalog.com)
 
10:00 PM
Not sure what to do with these last 3 operators...
 
@ only has one doc link anyway, so why not make it simply @ without saying what the operands are?
 
Idunno. Consistency? I suppose I could just omit them, yeah.
 
It just looks excessive when all have exact same description.
 
Does power look okay?
 
Also, you're missing f∘A
Uh, ¯A‽ It is just another case of f⍣A
Negative numbers are also arrays.
I'd call f⍣g "Until"
 
10:04 PM
Oh, true. I guess people can learn about inversing in the documentation itself. And yeah, missed that
 
Monadic is also "Over"
 
It is? I thought ∘, ⍤ & ⍥ were all beside monadically?
 
They are all atop monadically.
 
Dyadic operators sure are confusing
Thanks for your help
 
Beside isn't a good name, imo. I suggested "After" but that was turned down, probably because we don't have "Before".
But the names "Atop", "Over", and "Beside" all work for their monadic dervs.
 
10:07 PM
Gotcha
Well, I'm happy to have learned a few things doing this. Knowing how to make something work and understanding the concepts are clearly two different things
 
is possible to execute C code/Python code in APL?
 
I'd want to align these:
f∘g f∘A A∘f
f⍤g f⍤A
f⍥g
@Fmbalbuena Yes, C code using ⎕NA and Python code using Py'n'APL.
 
⎕←'Hello, World!'
Py'print("Bye, World!")'APL
 
@Fmbalbuena Hello, World!
 
@Adám ^
 
10:11 PM
?
 
Why the python exec not working?
print("Bye") prints Bye in Python
 
Uh, Py'n'APL is a library (follow the link!) and TryAPL doesn't have it loaded.
 
ok
Execute CMD (bash, batch, etc) in APL?
 
Oh, you misunderstood "Py'n'APL" as a syntax for executing Python. Sorry for confusing you there. It is just the name of the library.
 
@Adám I can't find one.
 
10:14 PM
It is the first two entries.
 
echo Hello, World! in batch/bash polyglot using APL?
 
⎕SH'echo Hello, World!'
 
⋄⎕SH'echo Hello, World!'
 
@Fmbalbuena
NOT PERMITTED: Illegal token
      ⎕SH'echo Hello, World!'
     ^
 
@Adám how to execute code?
 
10:17 PM
i.imgur.com/haMMpa4.png One last check and then I can stop bothering you '^^. Special syntax should be straight-forward
 
@Fmbalbuena The bot has restrictions. Use an installed system or TIO.
 
@FawnLocke Please don't stop; I keep leaning on F5 on your page to see if you've pushed. What happened to and ?
 
Oh, I completely forgot those!
 
@Fmbalbuena Try it online!
 
10:20 PM
If you put them below @, you could move to the end of the s though it breaks the symmetry.
 
Yeah, I'll have to decrease font sizes if I want everything to fit on one page without making that change. I'll have to bite the bullet
 
@FawnLocke Would it make sense to have each column of dyadic operators be a distinct ff fA Af or blank combo?
 
Hmm, that might work.
Lemme add variant and stencil first
 
Those are both fA
Actually, iirc, A⍠A exists but I've never used it.
Nope, I misremembered. f⍠A it is.
 
Gotcha. That could work then
 
10:24 PM
But there's only one instance of Af so you might want to let in a little irregularity.
 
Yeah
 
@FawnLocke What is "one page" on the web?
 
Whatever fits on my monitor :p
1920x1080 pixels is probably the most common resolution, baring any OS scaling. So I default with that for "one page"
 
Were you planing on adding a select subset of system names too, besides for "syntax"?
 
Maybe, if they're common enough. I talked in the past about writing articles for a given subject "Reading and Writing files in Dyalog APL" and going over the related system names.
⎕ML, ⎕IO, etc. Seem important enough to highlight.
 
10:30 PM
Ugh, can we not pretend they don't exist‽
 
I wish :)
 
single-letter system-names tend to be primitive-like, imo.
 
I can only think of ⎕C & ⎕A, I'm inclined to agree with how they're used.
I think ⎕C is actually monadic ⌊ & ⌈ in some APL derivative. But I could be wrong
 
⎕A and ⎕D (and ⎕Á…) are much like while ⎕R and ⎕S are similar to @ and .
@FawnLocke Yeah, my Extended.
 
True, true
Ah, okay.
 
10:33 PM
I later was convinced that that was a bad choice.
Oh, and ⎕SE is very much like #
I voted for ⎕DT to be named ⎕T but maybe it was good that it didn't get adopted, as ⎕DT isn't very primitive-like.
 
Quite useful, though. I can't remember how datetimes are done in K, but I remember them taking vital space
For...some version of K...
 
In Shakti Ks, they are a distinct datatype, indicated by multiple .s between digits groups.
 
I see
 
I really like APL's simple set of data types.
 
datetime is a distinct type in all versions of K to my knowledge, they also have things like a guid type
 
10:38 PM
I think one K actually has a bitcoin address type :)
 
Yes, newly added and restricted to only the kinds of strings that work for BTC addresses
 
Why, though? afaict, there's no valid manipulation of such.
 
It could make sense to have a "short string" datatype, I don't know if there's anything gained by making it so specific
 
At least dates and times and datetimes can be added and compared.
 
@Adám I'm guessing it has to do with kdb+ query optimization
 
10:40 PM
Couldn't they just be symbols?
 
Some big crypto exchanges use kdb+, I'm guessing they found a use case where the special type speeds things up, perhaps with the special type you can very quickly process BTC address columns
 
!
 
If you have transaction records where some use BTC and some don't, the special datatype could allow you to quickly filter BTC transactions from others
 
K: HFT DSL APL
 
Oops, that last ∘ is supposed to be A∘f
 
10:52 PM
@FawnLocke That looks nice, but if you want to save 1.5 lines, it wouldn't be too terrible to put between . and , at least until I get my will with f⍥A
Or actually, there are only 3 columns here, while the functions have 4 cols…
You could put and in a separate column.
 
That's true. I like the order of ∘ ⍤ ⍥, though. And, yeah. You can make replace and f∘A their own columns but you're sacrificing order somewhere or introducing bad spacing
 
Wait, I have an idea.
 
f⍣g f⍣A     f.g
f∘g f∘A A∘f  @
f⍤g f⍤A     f⌺A
f⍥g         f⍠A
 
Yes, that's great. The best compromise, I think.
Thanks a ton
 
10:56 PM
Alternatively, the rightmost column could move all the way left. Either way.
Though I do think the above will look the most balanced.
 
I agree
 
If you want, you can swap and @ to separate even more from A∘f
 
Nice idea.
 
(It looks most separate as I wrote it, but I don't have the labels on, and is the only one without label on the left.)
In fact, you might want to put . at the bottom right, so it can kind-of connect with its peers across the empty space.
f⍣g f⍣A     f⍠A
f∘g f∘A A∘f f⌺A
f⍤g f⍤A      @
f⍥g         f.g
 
Yep. I think that's the perfect iteration.
 
11:01 PM
Even if we add f⍥A it isn't a problem at all.
 
Quite the space save, as well :)
 
This is awesome. Maybe you can save even more space by moving the legend into the header? You can also remove "Primitive" imo.
Would it be an idea to align with APLcart and use X instead of A? Or even X and Y the way APLcart does it?
@FawnLocke A∘f should be A∘g no?
 
Yes, I can make those additions. Also, correct.
 
A is more mnemonic for Array than X and Y though, but maybe that doesn't matter much.
Otoh, Dyalog calls Agh trains Agh…
I can't wait to see the live site.
 
11:16 PM
@Adám Perhaps. I've only looked a little into it; it's a bit intimidating as the first thing I was met with was that I had to change my keyboard layout, haha. :)
 
@Nick You don't really have to. If you use the RIDE interface, you have use a prefix key instead.
 
You can use backticks as a prefix in RIDE (and TryAPL)
 
Backticks are awkward on a Danish keyboard, but say ½ instead.
 
Is there TC 2d language interpreter written in APL?
 
@Fmbalbuena I don't know of any 2D language interpreters written in APL.
 
11:20 PM
I can only think of one 2d language
 
< is another viable option for Danish keyboards, if you're OK with using <+3 (or space) for <
 
The hottest language ever is a 2D language: en.wikipedia.org/wiki/HAL/S
 
:O, how interesting.
 
Could reach 1,650 °C/3,000 °F on the outside.
The only language where, if your program crashes, it blows up.
 
11:30 PM
> Or even X and Y the way APLcart does it?
What were you suggesting here?
 
CMC: interpret ℒight
 
@FawnLocke f∘Y and X∘g
 
Ah, I see.
Can do!
 
etc. oc.
@Fmbalbuena ⍞←⍣≢⍕#
 
CMC: interpret + (register is X)
(+)
 
11:43 PM
@Fmbalbuena ≢∩∘'+' Try it online!
 
no return
local variable
 
So there's no way to verify if it actually worked or not?
 
nope
using []<-f
 
Not sure what you mean by that.
 
⎕←f
 
11:48 PM
@Fmbalbuena
VALUE ERROR: Undefined name: f
      ⎕←f
      ∧
 
I got that much, but what are you trying to say? Would that be a method of verification?
 
yes
 
Ah, so you want it to set a variable, which can then be queried.
a←≢⍞∩'+' Try it online!
 
00:00 - 19:0019:00 - 00:00

« first day (1778 days earlier)      last day (866 days later) »