« first day (2903 days earlier)      last day (2234 days later) » 

00:41
Does anyone here have Clang with WASM installed?
sort-of, it took me a while to get it working and I think I'm using a nonstandard setup
@ais523 what is the output of echo "__SIZE_TYPE__ f1(__SIZE_TYPE__ delta) { return __builtin_wasm_memory_grow(0, delta); }" | clang -x c - -target wasm64-unknown-unknown -emit-llvm -o - -S -O0 for you?
what does -S do? I'm trying to understand that command line; also the executable I have is called emcc, not clang
I think it's some sort of wrapper around clang but haven't figured out how to run the wrapped program directly
anyway: t.c:1:48: error: use of unknown builtin '__builtin_wasm_memory_grow' [-Wimplicit-function-declaration]
I guess you'll need to wait for someone with actual clang
(I'm leaving chat now anyway, other things to do…)
00:56
@Adám Has ever saved you bytes in Dyalog APL Extended?
I haven't really used my extensions much, or gone over old solutions to see, but e.g. here it would take the place of the whole definition U←{⍵⍵⍣¯1⍺⍺⍵⍵⍵}
Hmm, today's date in US short-hand form is 1/9/19. There's probably a challenge in that fact
@Adám Hmm I guess it would often help in long programs
@lirtosiast Yes, anywhere where you need to do a transformation while the data temporarily is represented differently, e.g. bitwise operations would be ⍢⊤
I wonder if it's helpful in short programs though, like from-digits λx.9-x to-digits above
in Jelly, from-digits and to-digits were both one byte, so to be useful, the operator would have to be less than one byte
01:07
@lirtosiast Well, let's assume the I/O has to be in numeric form. f⍢⍕ would apply f to the string representation and then convert back to number.
@lirtosiast OK, that's because Jelly has lots of short built-ins.
True
But Jelly wins
@lirtosiast Jelly uses the entire codepage (and has some two-byters too). APL has a very limited vocabulary.
@Adám I'm not arguing that APL is inferior somehow
Just saying that in an ideal language, code should have no repetition or patterns that allow for further compression
01:11
@lirtosiast What about this? Multiply the anti-diagonal [ /] by 10. 10∘×⍢(1 1⍉⌽)
@lirtosiast In an ideal golfing language, sure. APL isn't one.
And it annoys me that in Jelly, the code D9_Ḍ seems to have structure that can't be easily compressed out
So maybe it isn't a meaningful pattern after all, at least not in Jelly's paradigm in this specific case
@lirtosiast Well, for every invertible transformation function, you could have an additional quick which does the transformation, applies a link, then undoes the transformation. You'll just run out of characters quickly.
For example if f∆ was defined as DfḌ you could save a byte with 9_∆ or something.
@lirtosiast If your transformation is complex enough, it will pay off to have Under. How about this one? Swap the top two elements of the anti-diagonal beginning one step below the NE corner: 10∘×⍢(3↑1 1⍉1⊖⌽)
@Adám Nifty
01:20
@Adám @lirtosiast Jelly is very, very far from ideal too :P
@ASCII-only by how much, do you think?
@lirtosiast and it should have no invalid program
Jelly's getting old
People are coming up with more effective langs
@lirtosiast Yeah, my model for is built upon two features of Dyalog APL that are essentially black magic: Selective assignment and function inverses.
01:21
@Pavel We're just yesterday's jam
Jli when
@Pavel wait what
@ASCII-only as in, how much longer do you think Jelly is than entropy, in percent? Maybe an impossible question to answer
@Adám Mathematica has them
@lirtosiast yeah i have no idea honestly, especially if you take into account the fact that pure entropy isn't ideal in byte-based machines (i think?)
but for longer jelly programs... idk. maybe 50% longer? (or around there, or lower)
@lirtosiast Wikipedia says Wolfram Language was influenced by APL.
01:25
I'm not saying that isn't true but it's pretty hard to see the parallels
@Pavel influenced != derived
...yes
and considering how extensive Wolfram Language (well, the current version at least) is, it's not surprising it would be hard to see the parallels
@ASCII-only It is true that there are features Jelly doesn't and may never have, that go beyond builtins
@lirtosiast why reply to this message :|
01:28
Type inference (Husk), declarative (Brachylog), functions with arity >2
well, more like, did you reply to the right message :/
Yes, I was making the case that Jelly is getting old and in a meaningful way
hmm. i thought Jelly still performs as well (or almost as well) as them most of the time?
plus, they're getting old too, are they not
0
A: Sandbox for Proposed Challenges

Neil A.Speeding up powers of 2 code-golf Create a function or program that indefinitely prints outs successive powers of 2 separated by newlines. However, the nth power of 2 must have a delay of 1/n seconds either before or after it is printed, but please specify this in your answer. If you choose to ...

@ASCII-only Yeah
@Pavel what exactly did you mean by this?
01:39
@lirtosiast I just see jelly losing more often recently
¯\_(ツ)_/¯
Losing to what?
IDK
It's been like a month since I've looked on answers on main
@lirtosiast Aaand I just realised I could easily golf 11 bytes off that one. Thanks!
I saw that broken arm, Pavel
@Pavel :|
01:50
Looking at 10 results from searching "jelly" and sorting by newest, jelly wins 7/10 with 05ab1e winning the rest
@Veskah what broken arm???
@ASCII-only ¯_(ツ)_/¯
was there a broken arm though?
@Quintec isn't there a script for that?
@ASCII-only ¯\_(ツ)_/¯
But you're right. Message history tells a different story.
01:54
Oh, guess I glanced up and saw / become ` \ ` and made assumptions
Speaking of broken lines
It hurts to live
02:08
@lirtosiast Probably but i don't know it
02:20
question: would you rather have || and && return a boolean or act the same as scripting languages do
@ASCII-only what type of language are you writing?
When is a stream architecture useful?
@lirtosiast wdym
@ASCII-only oh I assumed this was for a new language
What's it for then?
@lirtosiast it is
02:23
@DemCodeLines Stream architecture?
but... what do mean by what type
@El'endiaStarman i guess they mean like java streams/unix streams?
@DemCodeLines mostly when data is too big that it isn't really an option to load the entire thing into memory, i guess?
well, also if your stream needs to undergo a lot of operations since normally you'd need to build a new list for each operation (so... basically most things)
@lirtosiast :| no i meant what do you mean by what type
uh
well, is it a scripting language?
02:47
Infinite streams
> Cannot allocate more than 8 EiB
what have I done
03:24
@Downgoat Oh jeez is that a billion gigabytes
That's a fair few bytes. Can you allocate 8 EiB exactly, or is that not a supremum?
@lirtosiast hmm. kinda, i guess
@Khuldraesethna'Barya 8EiB can be allocated but one more byte above that and things breka
Ah. Mind if I borrow your computer?
where borrow := steal
I want those bytes
@Khuldraesethna'Barya doesn't work like that :P it's just that current 64-bit architectures don't really allow for >8EiB to be allocated
not that any computer will come even remotely close remote
03:29
@ASCII-only 64bit arch can but I cast ui64 -> i64 that causes issues
>FizzBuzz Enterprise Edition is a no-nonsense implementation of FizzBuzz made by serious businessmen for serious business purposes.
03:51
> VSL: first allocation
VSL: out of memory
Uncaught (in promise) RuntimeError: unreachable
well that went well
04:50
:O my malloc implementation works
Unpossible!
05:28
in a realloc() is the new additional memory initialized?
 
1 hour later…
06:32
0
Q: Find is string is magic or not

Abhishek KumarA string is a magic string if - It consists of only digits - The digits form 8 unique numbers between 1 and 80 - All the digits are used - Digits must be used in order - No two numbers should not use the same digit in the string Write a program which given a string as input prints out all the se...

 
2 hours later…
08:45
@Veskah you're several years late in finding this
09:24
@Veskah they test for nondivisibility by 3 and 5 ... and then again by 5 and 3, just in case...
@Neil where
10:07
it's called NoFizzBuzzStrategy or something like that
10:55
3
A: Vertically collapse text

AdámAPL (Dyalog Extended), 13 11 bytesSBCS -2 with my extensions to Dyalog APL. Anonymous tacit function, taking and returning a character matrix. ~∘' '⍤1⍢⍉⍢⊖ Try it online! ~ remove ∘ the ' ' spaces ⍤ from 1 rows (lit. 1D sub-arrays) ⍢ while ⍉ transposed ⍢ while ⊖ flipped

 
3 hours later…
ngn
ngn
13:37
@Downgoat i use clang v6 from debian and i'm getting the same error as ais523
@Downgoat you decided against buddy allocation? what you have there looks more complicated. i'd also expect it to be slower - you search for a suitably-sized free block in a single linked list. with buddy allocation blocks can only have one of <64 discrete sizes and are segregated in separate linked lists, so you don't have to search.
there would be wasted space at the end of the block, but who cares - x86_64's address space is practically unlimited. virtual memory will make sure to materialise in ram only those pages you actually touch
BMO
BMO
14:45
May I get some feedback on my question here?
(It doesn't require a textual answer, just upvote one of the two comments..)
(Of course, I'm open to other feedback too)
 
3 hours later…
17:30
@ngn yeah you would need a custom clang build to ensure wasm support but after digging through source code I found the bug anyways though :P
17:42
0
A: Sandbox for Proposed Challenges

Arkinethis is my first question, make sure to tell me if anything could be worded better or if anything is spelled wrong etc. KoTH: iterated Nash bargaining! In this king of the hill challenge, you must play an iterated Nash bargaining game (https://en.wikipedia.org/wiki/Bargaining_problem). You and...

@BMO potential thing is to just require a guarantee that pi(x) != x but that might eliminate some unique solutions.
BMO
BMO
@HyperNeutrino I'm doing that (banning the identity \$x \mapsto x\$) in any case.
I don't think Jelly, score 0 or the various other empty programs will be particularly interesting.
It should be: You need to implement something interesting while keeping your score low. Trading bytes for a smaller score, but trying too hard to minimize the score will be penalized (unless you manage to stuff all that complexity into one bytes and map it to zero) due to using many bytes
17:58
"trying too hard to..." sounds like troubles :P
@BMO Oh, that reminds me you need to use the standard unary-prevention trick
Add the length of code to the score
Otherwise people will have like gigabyte long code where almost all of the characters have score 0
BMO
BMO
18:39
@lirtosiast Oooh, good catch!
@lirtosiast Why almost if you can do all :P
All would win in Unary, but almost all would win in every other language too, which would be unfortunate.
BMO
BMO
@lirtosiast But the almost part would be the interesting part, no?
basically, in Python 2, you can't encode the print statement with null bytes... ;)
BMO
BMO
For a lot of languages you can't pack too much into one character
@EriktheOutgolfer ^
yep
a character can only go up to 1114111, and you have to avoid surrogates too
well... maybe you can encode a whole program with null bytes
but the exec part plus the required quotes will be non-null, hence "almost all"
so no, the almost part isn't necessarily the most interesting one
BMO
BMO
18:44
@EriktheOutgolfer Probably only unary
I mean alongside the exec command
plus the processing required to parse those nulls
(which most likely would be an ugly brute-force abomination of a program encoded as a single integer)
BMO
BMO
Taking this route, you'll most likely end up trying too hard and be better off without trying to stuff everything into null-bytes
another boring approach (but very difficult to create a program for) would be to encode the program's bytes according to their frequency in it
for example, my program is reeeeeeeeemeenefgheee that encodes itself as 100000000020030456000 (code points), and decodes these code points back to their respective characters, and leaves everything else as-is
BMO
BMO
@EriktheOutgolfer Wouldn't that fall into this loophole, there is no such codepage afaik
what? note that the code points are all single-digit, I'm just bored to separate them :P
the decoding happens so that the program is a permutation
BMO
BMO
18:51
Ah, misunderstood that
however, what if we combine that approach with the null-encoded program approach?
BMO
BMO
Probably the best thing to do, is just say natural numbers don't include 0.
(even though it hurts)
in this case, we'll want to start with 1, not 0, use that translator as the encoded program, and then translate the characters of the encoded program's decoder
hm, yeah, that will hurt this approach :P
BMO
BMO
It gets close to golfing now, just more difficult yet more freedom since it's your choice of permutation.
that would also disallow my solution having any null bytes in it
BMO
BMO
18:56
Yes, but can a Python program even have literal null-bytes?
in a string I think yes
don't trust repl.it too much, btw
BMO
BMO
@EriktheOutgolfer Try it online! as comment it works(ish) on TIO, but inside string it didn't
interesting, tbf I've never actually tried that
just too bored to cope with the inability to copy-paste those things
BMO
BMO
Neither Python 2 nor Python 3 support them inside strings, giving SyntaxError: EOL while scanning string literal
@EriktheOutgolfer I generated the link containing the null-byte, seems like it's the easiest way to do.
it's easy to generate a TIO link?! I usually use the console to put nulls in TIO
BMO
BMO
19:04
Or like this on my system
@EriktheOutgolfer Use your favourite answer here
Usually I also use, printf "\xXX | xclip but that doesn't work with nulls like you said
19:36
Some spammer failed at a mail merge:
Dear {{first-name}},
I am interested in your product {{product-name}}. Please contact me back at {{email}} at your convenience.
"{{first-name}}"? somebody's stalking you...
 
1 hour later…
21:02
@ASCII-only If I was cutting edge, I'd be a brogrammer

« first day (2903 days earlier)      last day (2234 days later) »