« first day (2846 days earlier)      last day (1980 days later) » 
00:00 - 05:0005:00 - 00:00

12:36 AM
0
A: Sandbox for Proposed Challenges

BubblerQuaternion square root code-golf math complex-numbers Background Quaternion is a number system that extends complex numbers. A quaternion has the following form $$ a + bi + cj + dk $$ where \$ a,b,c,d \$ are real numbers and \$ i,j,k \$ are three fundamental quaternion units. The units have t...

 
1:22 AM
0
A: Sandbox for Proposed Challenges

MichaelFreeChat Online It is 1985, and you are a humble Russian potato farmer. Sadly, your glorious homeland is going through a time of crisis and it needs your help! The KGB, with the "assistance" of your wife and children, has convinced you to build their up-and-coming government FreeChat Online serv...

 
(perl5) Is there any way to:
1. print *anything* to stdout shorter than 7 bytes
2. error out in eval
 
1:59 AM
@NewSandboxedPosts is there a close reason for "'cia propaganda".
 
@quartata Don't deny your involvement in this
 
@user202729 say'42', requires the -M5.10 flag (or a higher version)
say appends a newline automatically
You could also use the -p and -n flags for super short io, see perldoc perlrun
 
i will deny it
if you could first just tell me what the word "this" is that would be very nice. thank you.
 
if i were a kgb agent, i simply would have stopped the soviet union from falling, thus avoiding lots of potential issues for it down the line. i dont know why they didnt think of this
 
2:19 AM
@ETHproductions i've found them generally on their licenses or websites
@LuisfelipeDejesusMunoz you can always ask the authors of those languages :P
@Dennis yeah. especially because being the one that wrote it, it's generally still fresh in their memory
 
@LuisfelipeDejesusMunoz π”Όπ•Šπ•„π•šπ•Ÿ is the only other one I know of.
 
Tfw your new headphones finally arrive and you have to charge them for sixteen hours.
Phone chargers spoiled me.
 
@Dennis Is this related to your power grid problems
My bluetooth headphones charge fully in like half an hour and last me several weeks
 
No, the manual says 16 hours.
 
TeaScript was actually the first, and it inspired me to write the interpreter for Japt (I'd already had the idea but hadn't implemented it), then π”Όπ•Šπ•„π•šπ•Ÿ came in around the same time as Japt. We had a mini-competition going on between the three languages for a few months :-)
 
2:27 AM
then everything but japt basically died :P
@ETHproductions btw why does japt have so many todos :(
 
Case in point, TeaScript has no surviving interpreter :-(
 
it... what O_o
 
@Dennis That's... really weird
 
wasnt there a fourth JSGL
uhhhhhh
 
@ASCII-only are you looking at Japt v2--wait, nevermind, I see what you mean. I can't implement them all you know :P
 
2:29 AM
@ETHproductions can't?
also hmm
maybe i should make charcoal transpile to js :P
 
I actually only have 3 reserved letters left for array methods
ü, ý, and þ I believe
 
oh :|
 
Of course, Japt doesn't use 65 of the 256 bytes (outside of compressed strings)
 
0/10
 
and even in compressed strings, 0xF0-0xFF are still useless
consequence of the choice of compression library
 
2:31 AM
shoco?
 
its kind of interesting how people were upset about golfing languages in gneral and there were so many and then the introduction of an even more flexible golfing language kind of took care of those problems
 
even more flexible?
 
gelatinous
 
@Pavel It comes with NiMH batteries. That's probably why.
 
2:33 AM
@quartata how did it take care of the problems tho
 
Ah
 
16 hours is for the first charge. It's 8.5 hours after that.
 
well we kind of only have two general-purpose golfing languages in consistent use now
 
@ASCII-only right, it dedicates 64 bytes (0x80-0xBF) to 2-to-1 compression, then 32 (0xC0-0xDF) to 4-to-2, 16 to 8-to-4, and so on. 8-to-4 is already buggy beyond use, and when you get up into 16-to-8 it starts somehow entering an infinite loop when attempting to decompress the string.
 
you what
what is this terrible compression :/
 
2:34 AM
Now that I think about it, I don't think 0x00-0x1F are used in compressed strings either :P
It's not terrible, it's actually really good at compressing strings of lowercase letters.
nothing else though :(
 
hmm. actually. maybe it's about time for charcoal v2?
 
"somehow entering an infinite loop when attempting to decompress the string" um ok completely normal
 
@ETHproductions compare it with charcoal's
 
15
A: Shortest Code to Legitimately Slack Off

ETHproductionsJapt, 2 bytes `ΓΏ You can test this online here, but I wouldn't recommend it as it will freeze your browser. Explanation Japt uses the shoco library for compressing strings. A backtick tells the compiler to decompress everything until the next backtick or the end of the file. Each byte does t...

 
also. charcoal still doesn't have dictionary compression because i'm not sure what would be a good way to do it
 
2:36 AM
Hey man, I haven't even planned dictionary compression for Japt v2 yet
 
@ASCII-only steal jelly's
 
@ETHproductions apparently shoco is only a dictionary compressor tho?
basically
 
@Pavel None works with A Pear Tree :(
 
@Pavel hmm. well charcoal does have brotli tho
 
(I was tryimg to crack ais523's cop submission)
 
2:37 AM
@ETHproductions Darn, I was hoping for an interesting explanation as to why. :P
 
@ASCII-only It's based on the english dictionary, but isn't in itself a dictionary compressor in the traditional sense. I guess you could still consider it one, just mapping sequences of bytes to specific sequences of lowercase letters
@Quintec Maybe one day I'll dig into that awful minified source code and find out what exactly goes wrong :P
 
That sounds like torture
 
@ASCII-only If we don't care about speed and memory requirements (which we don't because code golf), PAQ: github.com/hxim/paq8px
 
It's minified C compiled through Emscripten to JavaScript and then minified again
 
@ETHproductions just compile it yourself
with the newest stable version of emscripten
 
2:40 AM
PAQ is like, the best compression
 
Now that I think about it, a minified functional Java golf lang would be pretty cool.
 
@ETHproductions github doesn't count????
 
And it does in fact take under an hour to compress Hello, World!
 
To how many bytes? :P
 
I don't remember
I think it made my entire computer unresponsive and then I just nuked it
 
2:42 AM
:|
 
So into 0 bytes!
 
But not with HW, right?
 
I actually tried it with a pdf of the core rulebook of The Dark Eye
Which is substantially longer
 
@quartata two???
 
@Quintec What about Java makes it particularly good for functional programming?
 
2:44 AM
is everything other than japt and jelly dead :P
 
@Pavel Absolutely nothing, but java functional programming is cool ^.^
 
@Quintec Have you tried other languages that allow functional programming
It's a lot cooler than Java's way of doing it
 
Interestingly I just noticed Alex A. has ported shoco to Julia
 
Well, C++ functional programming is probably even worse, but other than that
 
@ASCII-only i was actually thinking jelly and matl
 
2:45 AM
huh, MATL
 
sure you have your specialized stuff but
 
well. not surprising. it has industry grade documentation :|
 
I would say APL is rather alive
 
APL isn't a golfing language though
 
but... are 05AB1E, Japt, Actually and the like all dead. also ^
 
2:46 AM
@ASCII-only Are they actually dead
 
APL and derivatives are not golflangs
 
@ETHproductions alex has ported everything
 
@Quintec :|
 
osable is dead last i checked
 
2:46 AM
Hey, someone was going to go there sooner or later
 
wait, when did 05ab1e die
 
@quartata @ETHproductions they're wrappers not ports
 
Brachylog is really good at squares and that's all I know about it
 
i know. its just ffi.
 
ffi? Frabjous Fractran Interpreter?
 
2:48 AM
@Pavel also amazing at things prolog is good like. e.g. reverse fibonacci
 
foreign function interface
 
also i remember how much time i wasted on this >_>
oh yeah @Dennis when are you planning for jli to be a thing :P
 
Not sure yet. Not enough time.
@ASCII-only O5AB1E and Japt are actually pretty close to Jelly.
 
@ETHproductions it has =D
 
@Dennis *05 :P
 
2:54 AM
Right
 
@ASCII-only I think Emscripten actually might minify it itself, since it can't recover function and variable names from the bytecode, right...?
 
@Quintec yeah. why not just use a purely functional language like haskell or its derivatives
 
Because I don't feel like learning a new language, lol
 
@ETHproductions possibly. but i mean it's possible the bugs have been fixed with a newer emscripten
 
2:56 AM
Something about Java's way of using OOP to implement functional programming makes it horrible and beautiful all at once
 
@Quintec no... i mean just use... idk. haskell? common lisp? clojure? parenthetical?
@Quintec most certainly not. just horrible and terrible all at once
 
nononono
 
seriously. even C# is way better
 
@ASCII-only chat.stackexchange.com/transcript/240?m=47334830#47334830 and Japt was also at Sep 20 when this was posted
 
@Quintec Just learn C#, it's like Java but with sane functional programming capability
 
2:58 AM
Help I'm being persecuted for my beliefs
 
And when I say it's "Like Java", it's really like Java
You can pick it up in half an hour
 
except golfier ofc
like no extends and implements for one
@Quintec yes bc javaism is the programming equivalent of satanism
 
@LuisfelipeDejesusMunoz brb adding link in golfing-langs :D
 
@ASCII-only Also is and not Instanceof, int? and not Integer, [0] and not .get(0), etc.
 
and C#7
 
3:01 AM
Yes
and tuples
 
also availability to overload operators
god bless C#
 
oh yeah that's a really important improvement
tbh i'm more surprised java doesn't let you do that
 
That's not really a golf feature except when it's been done beforehand by library designers
C# has some lovely non-golf features, like structs, properties, async, linq
 
i still think linq is weird
 
What part of it is weird
 
3:03 AM
the fact you can write a sql query in c#
like... var foo = select property from data where conditions
 
You can just use the method form instead of the keyword form
 
Any way to shorten tio.run/… ? Assune:
 
@ASCII-only The designers thought it would make code harder to read. The JVM does support it however, and String overloads +
 
oh yeah var is good too. java's finally catching up
 
1. The header is unchanged
 
3:04 AM
When dealing with BigIntegers I MEAN I JUST HATE HOW JAVA MAKES IT VERBOSE AF
even js BigInts uses operators
 
Java does have BigDecimal
C# is just stuck with normal, 128-bit decimal
 
ES2020 makes BigInts in JS easy as pie, just type 1n and boom, a BigInt appears
No BigDecimal though
 
2. It's necessary to have an expression that evaluates to the source code
 
Oh its confirmed ES2020?
 
(not yet, I'm assuming things lol)
 
3:06 AM
iirc it's still in Stage 3 because Firefox is still on its slow pace implementing BigInt
 
still at stage 3, tests ready but not merged
oh, does it only make it to stage 4 once all major browsers have an implementation going?
 
Oh, we also have nuget in C# land
 
iirc two different implementations?
 
@Pavel and chocolatey :P
 
but so far only V8 has finished implementation
 
3:08 AM
Now, Dennis could tell you all the reasons why nuget is not the most amazing language-specific package manager, but Java...
 
52 bytes so far (sorry for interrupting)
 
You can take Java away from my dead body
 
Personally I think Nuget makes some really good decisions that make it a lot more usable than Pip or Gem or Cpan or whatever
 
goes and hides in a corner
 
3:10 AM
@Quintec The first step to a better life is admitting you have a problem
 
@user202729 not allowed?
 
@ASCII-only Yes, "expression evaluate to soirce code" is i,portant.
 
@user202729 ???
 
I alsp tried various combinatiom of __END__/DATA, too long.
read $0 doesn't work because A Pear Tree.
7 mins ago, by user202729
2. It's necessary to have an expression that evaluates to the source code
 
@user202729 wait wat
why though
 
3:14 AM
@Pavel But does C# have... thinks frantically uh... I don't know, multithreaded concurrent stuff?
 
@Quintec yes, why
 
Actually DATA is shorter but
 
But is it good
 
@user202729 ?
 
@ASCII-only I intend to use the src to do other things not just src
 
3:15 AM
@Quintec yes why
 
@Quintec Way better than Java's
See async/await
 
@ASCII-only I intend to use the src to do other things not just print
 
@user202729 wat
 
java has those
 
No as keywords
 
3:15 AM
(as I said abv I was trying to crack ais' cop submission)
 
@Pavel and threads too
 
Like you can declare a function to be async and it'll automatically run on it's own thread when you call it
 
@user202729 link pls
 
And then you can await the result
 
@Pavel oh wait yeah
also. lol, canvas, charcoal and bubblegum appear to somehow be tied for this challenge
 
3:18 AM
Time to write only java answers forever
 
@user202729 oh i see. then no need to print
 
@Quintec Here, look: tio.run/…
 
yield return in C# is just so good to write an async task especially when using Unity
 
Also generators
 
In java you need to use threads, and boom RACE CONDITION
 
3:24 AM
Well you can't get rid of race conditions
 
B-b-b-but CountDownLatches!
 
oh @user202729 what even is <DATA>__END__
@Dennis aw :P
 
We have Events, too
You can also, more simply, await a list of tasks
 
@Pavel That doesn't have encapsulation, I refuse :P
 
@user202729 does this work
 
3:38 AM
Ok, no...
The program must
1. On empty inpitm print something
2. On input nonempty, with -p0777, different from src, print something
3. on input eq to src, print nothing
'src code here'ne$_||die;print 1 would work
Reading DATA won't work b'c APT append a newline to end of source code.
Fortunately thanks to p0777 the whoke input is slurp at once.
 
what happened to your typing :|
 
-p0777 is this permission?
 
oh so no need to undef $/? @user202729
@user202729 so it's ok as long as newline is trimmed?
 
I think appending a newline and force scalar <DATA> would work.
@ASCII-only Yes.
 
wait <DATA> not scalar???
@user202729 trim might work too???
 
3:48 AM
@ASCII-only In print it isn't.
 
but why print???
 
Because I realize I don't need it.
 
also damnit perl 5.0 doesn't have print
 
Ok, it should work.
So seek*DATA,-47,2;<DATA>ne$_||die;print 1;__END__ with a trailing newlineshould work
but it's just too long already.
(note that APT append some code to the beginnung too, so seek with WHENCE 0 don't work as expected)
 
how much code to beginning :/
 
3:53 AM
More than100 bytes. It can be determined but don't save any bytes.
 
seek*DATA,-47,2;print<DATA>ne$_;__END__ or something doesn't work????
or seek*DATA,-47,2;print$_ne<DATA>__END__ or w/e
 
@ASCII-only p0777 auto print. die is necessary when $_ eq src.
 
Or $_='' which is longer.
 
if auto print then why need print at all????
 
3:55 AM
@ASCII-only Without input no flag is given.
 
oh true :/
and say doesn't work bc it's not >5.10 :/
 
0
Q: FreeChat Online

MichaelFreeChat Online It is 1985, and you are a humble Russian potato farmer. Sadly, your glorious homeland is going through a time of crisis and it needs your help! The KGB, with the "assistance" of your wife and children, has convinced you to build their up-and-coming government FreeChat Online serv...

 
@NewMainPosts Oh dear, it's been posted already
 
@user202729 wait why __END__?
 
regex may help somehow.
@ASCII-only shorter than __DATA__.
 
3:58 AM
seek*DATA,-47,2;<DATA>ne$_||die;print 1#foo (comment) doesn't work???
oh wait
 
Tried to include as many variations as possible of each language name
 
We also need about 4~6 more bytes to satisfy CRC32 requirement.
(I have a CRC32 solver)
 
> 18 Charcoal
wow Neil is really, really active :/
 
Top 10 golfing langs: Jelly, 05AB1E, Japt, Pyth, Charcoal, Stax, Retina, MathGolf, MATL, Brachylog
 
@ASCII-only In my testing __DATA__ or END is necessary for DATA to be usable.
 
4:02 AM
oh :(
@ETHproductions when an ascii art golflang is 5th
and a regex one is 7th and an imperative one is 10th. there really are a lot fewer golflang submissions than we thought. or fewer golflangs than we thought
@user202729 oh yeah, regex how :/
 
Idk, /something/ may be shorter than $_eq'something'
 
@ASCII-only Fun fact: there are only 71 GS2 answers
 
even though it's one of the few golflangs on anagol :P
 
GS2 gets a score of Oct 11, 2015 :(
 
O_o wow
 
4:08 AM
What, Japt is 3rd?
It's probably the only language that benefited from LotM
 
common lisp looks like it gets around jan?
tcl about april
 
@Bubbler I'm really lucky to have had Shaggy in the Japt community at that point, he did most of the advocating, and did a great job of it :-)
 
clojure gets around feb
so surely golfscript isn't the 40th?
also @ETHproductions oi, perl 5 != perl 6
 
and python 2 != python 3
or is the difference greater than that
 
much, much greater
i'd say even greater than python 1 vs python 3
 
4:14 AM
@ASCII-only no, it's probably more like 50th-60th
 
Python 2 and Python 3 have minor differences. Perl 5 and Perl 6 are completely different languages.
 
XD yeah you're missing the mainstream languages. the ones i'vementioned and other ones. e.g. prolog
 
ok, I'll see what each of the Perls get individually.
 
looks at prolog result screen
ignore that one, that's just me bloating answer count
 
Perl 5 is Jul 27
Perl 6 is Oct 26
so Perl 6 is still 3rd (tied with Jelly), Perl 5 is more like 26th
@ASCII-only yeah, with some languages more than others you have to be really careful how many answers you include. I'm already excluding answers on questions tagged polyglot, koth, or tips
 
4:18 AM
no as in look at the submission authors >_>
 
K was one of the worst, surprisingly C wasn't too bad
@ASCII-only oh lol
 
C is one of the craziest when it comes to golfing IMO
 
that's impressive that you managed 22 Prolog answers in a row xD
 
tbh they were only on old, easy challenges that made it to the front page
add that to the fact basically nobody uses prolog anyway
 
well, there are around 360 Prolog answers, and of your 24, 22 ended up in a spell where no one else was writing them
and 10 other users have used it in the 5 months since
 
4:24 AM
Best without reading src: 68
Best with __DATA__: 48 (inreal code rplc 48 wt 49)
Is there a way to terminate program inside eval? (perl5)
Ok, apparently exit works but die doesn't.
Best with eval: 47 (actually 46 in APT)
but crc32 makes it 52 :(
 
@user202729 can you remove the $ in $x
 
@ASCII-only Only in APT, and only 1 of them.
(the one outside string interpolation)
 
@user202729 which means you can remove the one inside as well
 
Oh right.
44 eval(x=q["eval(x=q[$x])"ne$_||exit;print 1])
(not tested)
Hm...
 
44???
 
4:37 AM
@ASCII-only Yes, the backslash for escaping $ can be rm too.
 
would eval(x=q[/eval(x=q[$x])/&&exit;print 1]) (40) work?
(no, because $ and () are interpreted as regex metacharacter)
Any workaround? ...
 
$ looks fine since it's inside []
 
@Bubbler But [] will need to be somehow escaped too...
 
Yeah, that's the problem
 
4:40 AM
Adding too much \ will destroy the advantage of regex,
and m'....' won't work b/c $x need to be interpolated.
Oh there is \Q.
 
@user202729 wait that interpolates $x?
 
Is there somewhere where I can download all answers (or even all posts) from PPCG?
 
@user202729 you don't need sprintf to write a quine in Perl/A Pear Tree, and it's one of the most verbose ways of doing it; my first A Pear Tree quine was a= "print('a=',repr(a),';eval(a)#r3TQJ')" ;eval(a)#r3TQJ (this also works in Python 3)
 
@ETHproductions nope
@ETHproductions well. SEDE's weekly backups might work?
 
SEDE will give me 50K at a time, I guess that will work
 
4:45 AM
@ais523 I remember trying repr+"...", doesn't work too
 
@ETHproductions no as in the db download
 
btw, I normally test A Pear Tree programs by sticking a #r3TQJ in the header, that string (followed by newline) has a CRC-32 of all zeroes
 
@ASCII-only link? (I can't reply for some reason)
hmm, it's better now
 
@ASCII-only I used to use it for PPCG, but it's so verbose :-( Nowadays I normally use Brachylog instead unless the program really needs to do things Brachylog is bad at
 
4:47 AM
last modified Sep 05, interesting
 
wait damnit
@ETHproductions well for smaller sites you can just start from the data dumps and update data using SEDE
@ais523 a language being verbose doesn't stop people from answering in it :P just look at java
 
@ASCII-only yes, but part of my motivation for code golfing is learning about language: "how concisely is it possible to express this idea, what sort of language makes it possible to be expressive in the same way that, say, English is", so shorter program = more interesting
 
also wait there's no a pear tree hello world yet???
 
there's one on TIO I think
 
@ais523 english isn't concise btw >_>
@ais523 wait true >_>
 
4:51 AM
it's just a Perl/Python hello world with a #r3TQJ stuck in front of it
to keep the CRC checker happy
 
@ASCII-only in SEDE, do you know if there's any way to get the tags of the parent question given a question id?
 
@ETHproductions parent?
someone really needs to add the rest of the TIO Hello, World! programs to codegolf.stackexchange.com/questions/55422/hello-world
@ETHproductions i'll look, brb
 
@ASCII-only as in the tags of the question the answer was posted on
 
Hm. Use regex won't save any bye because \Q^$ is 4 byte long alteady
 
@ETHproductions so given an answer id?
 
4:53 AM
well, I have all the data from the answer, including the id of the question it was posted on, and I just want to get the question's tags
 
now I'm glad I spent so much time golfing that A Pear Tree cop
 
@ASCII-only No....
 
not only did I have to golf it down to a pretty short length, I also had to try every variation of the program at that length to find one where I could slip in an ASCII CRC
 
@ais523 It's overgolfed for me :/
 
@user202729 ?
 
4:55 AM
@ASCII-only Sounds like answer spamming for me...
 
well
someone has to do it sometime
 
@ETHproductions just work from the question ID then, seeing as you have it; no "parent" relationship needed
 
@ais523 nah it's easy and super fast either way
 
@ASCII-only thanks, I'll see if I can work that in
 
@ASCII-only right, it's going to be indexed; but although the join is easy to write, there's no point in writing it when you have the question ID
 
4:58 AM
@ETHproductions if you want to filter in a SEDE query, you'll probably want NOT LIKE too btw
@ais523 not if you can't get the question ID directly (i.e. you'll have to get it from the answer ID one way or another)
but... maybe ETH really does have question ID already
 
@ASCII-only well, it depends on whether the scenario is "I'm writing a query, which will produce answer IDs and I can join on that", or "I already ran a query and now I want a followup query, how should I identify the rows I want to ask about"
 
00:00 - 05:0005:00 - 00:00

« first day (2846 days earlier)      last day (1980 days later) »