« first day (2924 days earlier)      last day (1911 days later) » 

12:07 AM
@ASCII-only oh, I meant to mention that PeekDirection(9, :Up) (or :Down) pads the output for some reason (:Left and :Right are OK though).
 
@NewMetaPosts As we push golfing languages ever closer to entropy maybe we will need to use AI
training a model to compress code, at least
 
 
1 hour later…
1:28 AM
@lirtosiast incorrect
A golfing language in which code is sorted by usefulness, yes
Anything other than that, no
 
MetaGolfscript is the future
 
2:00 AM
@ASCII-only I'm not sure what you mean by this
 
2:35 AM
0
A: Sandbox for Proposed Challenges

don brightGenerate a sequence of uninteresting numbers The OEIS Foundation's On-line Encyclopedia of Integer Sequences is well known around these parts for it's fascinating descriptions of interesting sequences of numbers. But what if you want to generate a sequence of uninteresting numbers? The OEIS is...

 
2:56 AM
@lirtosiast as in, i don't think it's hard to make a golfing language equally long as entropy, without AI
or barely longer
the problem would be having the most useful programs as the shortest ones
 
I think we mean different things by entropy
 
maybe :/
 
By my definition, to match entropy would be to build a superintelligence that knows the exact distribution of billions of possible code-golf challenges people pick from when posting to PPCG, and Huffman code from that distribution so no solution would be more than ~10 bytes long
 
i'd say it's impossible
even AI can't do that
the problem is... kolcom mostly
 
I'm trying to use Paypal and getting an error "the picture of your document isn't clear"
What do you think that means?
 
3:07 AM
no way a superintelligence will predict the next meme/a quote that doesn't exist yet
 
according to Larry Wall, perl is intended to be huffman encoded
 
@feersum id photo sumbitted to verify your identity
 
@ASCII-only Yes, that is the document.
My question is, what is the algorithm that decides if it's "clear"
 
who knows
 
@primo What
 
3:08 AM
@lirtosiast a joke on how Perl tries to make more common functions have shorter names
 
oh ty
 
or have shorter syntax, yeah
 
Unlike PHP, which just tries to make the name lengths be evenly distributed.
 
...because the devs couldn't figure out how to write a decent hash <_<
 
3:23 AM
@ASCII-only Yeah kolcom is uncomputable, plus the universe might be random
I think the majority of algorithmic code-golf challenges have kolcom under 10 bytes though
We have dupes so often, because people are drawing from a small distribution
 
0
Q: A Multipurpose Quine

KrystosTheOverlordI personally love quines, but they all seem to be so... static. So why not create a quine that can do more. Challenge Create a quine that, depending on its input, generates another quine (either a different language or something of the sort)! Requirements No examining source code directly. Ta...

 
@lirtosiast because If the is not a reason for competitive being important excluding the rules, then the reason must be including the rules — tuskiomi 23 mins ago
um can someone explain to me what OP is saying here?
 
looks like generating a different quine for each numerical input
obvious loophole: just tack the input into the quine somewhere
 
4:30 AM
obvious loophole: quine receiving inputs are not quine
 
Anyone have any experience with Selenium? The webdriver portion of it looks pretty meaty
Random aside: do you score that kind of command-line option? codegolf.stackexchange.com/a/179292/78849
 
4:46 AM
@Veskah If they claim that as a separate language, it would be cheaty. Score in C# should have the byte count difference between calling with option and calling without added to code size.
 
I see
 
 
3 hours later…
7:38 AM
@Veskah a little bit
 
 
1 hour later…
8:51 AM
@BMO ok. imo collapsing repeated steps (under -d2) and displaying universe after every step would be useful debug tools in Alchemist
@lirtosiast @Veskah Uh no, check consensus (well, I haven't actually read it. either they say something about options like this (and C's define options etc.) and I'm wrong, or that needs to be added to the relevant meta question)
@Veskah why selenium though
 
9:22 AM
@Veskah I've used it quite a bit.
 
10:04 AM
@ASCII-only You're right, I haven't read the consensus in a long while. The consensus mentions C where flags are required to specify, but I'm not sure how we're supposed to deal with flags like these (that seem to import automatically?)
 
10:47 AM
@lirtosiast I meant C's -Dfoo=bar define flags, which are equally cheaty
 
@ASCII-only even with more optimisation, I don't think the Alchemist quine would run in anywhere near reasonable time. for every character, it's trickling an extremely large number through a three step binary process and then back again, one atom at a time
 
11:16 AM
@JoKing you just need better optimization then :P
surely it's possible to convert a deterministic program into some kind of FSM or something?
 
yeah, but the quine isn't deterministic :( (at least not in the order of steps)
 
sure, but... deterministic program optimization is just the first step :P
i'm just thinking optimizing a nondeterministic program would be quite a bit harder (but still doable for many cases)
 
i did have an extra rule in testing that converted 8 of the basic atoms to the final atoms to make it like 20x faster
hmm. in my prime checker I saved a byte by removing a restriction, which ended up having the consequence that, as two rules were resetting the counters, another rule was undoing that work at the same time
 
haha
 
you probably can't optimise around that
 
11:23 AM
why not
also, it wouldn't be expected to, even basic optimization would already be massively useful for deterministic division/subtraction/addition
@JoKing oh also. shouldn't be hard to make it deterministic
 
i wonder if it has optimisations like 'only check rules that have a left hand side affected by the previous rule'
 
just generally it requires quite a bit more code
 
yeah, but it's code-golf :p
 
@JoKing any optimizations at all? i doubt it
@JoKing :| ok i'm going to find those two bytes to shave if it kills me
 
i'm going to have a look at the source code
 
11:29 AM
well it does have "optimize unreachable rules" as a recent commit
@JoKing here
is the main optimization. there might be more
 
yeah, i was just looking at that
i think that's about it though
oh, it does unify rules where there wouldn't be side effects
i think... I've forgotten everything i ever knew about Haskell
 
 
1 hour later…
1:04 PM
Working with some DBAs, troubleshooting slow responsiveness in a particular application. The DBAs discover a portion of code that is JOIN-ing 24 tables together and then SORT BY 46 different fields. It'll be interesting to see what the app vendor has to say about that.
 
Yeah lol I just had to do some maintenance the other day on some old DB functions here in my company. We found one that took like 50s to do an operation which shouldn't take more than .5
 
Hi. Any way to golf something like this: x==a*(a+14)||x==a*(a-14)
 
@LuisfelipeDejesusMunoz (x/a-a)**2==196?
 
@J.Sallé And then you find out that piece of code is called like 100x per day
 
@AdmBorkBork it's actually what triggered the need for maintenance in the first place, hahahah
 
1:19 PM
@Neil @Neil Would you mind explaining me how? I'm pretty bad at maths
 
Turns out there were 6 or 7 useless triggers being called by that function
 
1:57 PM
@LuisfelipeDejesusMunoz x==a*(a+14)||x==a*(a-14) => x/a==a+14||x/a==a-14 => x/a-a==14||x/a-1==-14 => (x/a-a)**2==196
 
user image
10
It's in LaTeX so it must be true
 
lovely
 
2:47 PM
Flawless logic
 
BMO
@ASCII-only: Wow, that's a lot of inbox messages generated by you :)
Sorry, I only get back to you now, I currently have exams which are somewhat more important than PPCG :(
@ASCII-only Yeah, that'd be a good one and also not a big deal to implement..
Once I'm finished with my exams (11th) I'll have a week off, will start to implement your suggestions then. I'll get back to you
 
3:28 PM
0
A: Sandbox for Proposed Challenges

Black Owl KaiPlaying Pickomino code-golf game In the game Pickomino, there are several tiles lying in the middle of the table, each with a different positive integer on them. Each turn, the players roll dices in a certain way and get a score, which is a nonnegative integer. Now the player takes the tile wit...

 
4:22 PM
@Pavel it's clearly working harder than normal
 
All the things.
 
4:45 PM
I still don't understand "A Multipurpose Quine" challenge.
 
I actually think it's an awesome idea, it's just that The output cannot just be a copy or an altered copy of the original, no appending or deleting characters of the old quine into the new quines kinda makes it subjective
Isn't every string just some other string with all of the old characters deleted and a bunch of new ones appended?
Setting that aside, This V program technically meets all of the requirements, and has a score of infinity.
 
Yes
 
@DJMcMayhem hax!
 
How's that?
 
It was a joke because of the infinity score
 
4:56 PM
@DJMcMayhem I don't understand, shouldn't 17i17i insert "17i" 17 times?
i.e. not twice
 
Check the hexdump ;)
 
wat
pls explain
i'm scared and confused
 
<M--> and <M-+> are essentially -1/+1 to the count. So 4<M--><M-->i4<M--><M-->i really means 4-1-1 (2) times, insert "4<M--><M-->i"
I keep coming back to that answer hoping that I might one day be able to get it to a score of 6, but I'm afraid it's impossible.
 
@DJMcMayhem That actually has a small typo: '5----a' and not '5---a' at one point
 
Ah, tyvm
 
5:23 PM
0
A: List of bounties with no deadline

DJMcMayhemUp to 500 rep for beating me at Write a Quine Suite I will give a bounty to anyone who can beat me at this challenge. For the record, the scoring on that challenge is: Most quines wins. Shortest sum of quine lengths is a tie-breaker. Currently, I hold the record on that challenge with a sc...

 
5:37 PM
0
A: Sandbox for Proposed Challenges

AdmBorkBorkFind the needle in the haystack code-golf string Given a rectangular haystack composed of all the same printable ASCII characters, output the location (counting from the top-left) of the needle which is a different character. For example, if the following haystack is input: ##### ###N# ##### ...

 
6:20 PM
Wilderabeest with moves of 1,2 + 1,3 + 1,4: Reached position 1736708854818 (pruned to 1556319310032; max previously visited: 1736703583468); this exceeds allocated array
 
So you ran out of memory?
 
Pretty much. I gave it 21e9 bytes to work in, and it used them all up.
 
So you ran out of a lot of memory.
 
Yep, I only have 32 GB.
 
"only"
It wasn't too long ago that 32GB was massive for a hard drive, and unthinkable for memory.
 
6:34 PM
um, 32 GB is still quite large...
 
I remember when 32MB was unthinkable for memory.
 
@EriktheOutgolfer For a hard drive?
 
no, for RAM
 
Yeah! My first PC had a 20 MB hard drive and 640 KB of memory.
 
6:35 PM
Yes
 
My first PC had 0B hard drive.
 
I remember how unimaginable it was when I heard of some supercomputer having gigabytes of RAM. I think at the time I didn't even have a gigabyte hard drive.
 
My first PC didn't have a hard drive, and only 5KB of RAM.
 
@AdmBorkBork But it probably had TWO 5.25" floppy drives, right?
 
I can't remember if my first had two or just one 5.25" floppy drive...
But my second had one 5.25" and one 3.5".
 
6:38 PM
@Adám No, cartridge based.
 
At first used them as A: and B:, but later remapped them to B: and A:.
 
@LuisfelipeDejesusMunoz I don't really know JavaScript, but that looks pretty golfed to me.
 
@Riker found a gem
 
@AdmBorkBork Cartridges? Such newfangled nonsense. What's wrong with punch-cards?
 
I'm very thankful I never had to deal with punch cards.
 
6:46 PM
Ever dealt with 8" floppies?
 
no
 
No, but my school had a couple old machines that had them. Never used them.
 
(oops, can't edit older messages – not that it's a big deal, but I gave it 21 GiB, not 21e9 bytes.)
 
I'm old enough that I had a "keyboarding" class. I hated it, too, because it was graded on % improvement, but I went into the class typing 80 wpm, so I didn't have much improvement. :-/
 
That's the stupidest thing I've ever heard
 
6:54 PM
yeah, that, wut
 
(not the typing class, but the grading)
 
well if you know it in advance I'm sure you could type 1wpm if you want to
@AdmBorkBork actually I think I would really like to experience that:)
 
Yuck. At what point did you find out it was graded that way?
 
Would have been fun to try and see what you'd get if you have like 10 wpm in the final test:)
 
@Deadcode About halfway through the trimester.
 
6:57 PM
ouch, too late by then?
like, wtf is going on with that grading
> oh hey I have nothing to teach him let's give him a 0
 
Pretty much. It was kinda frustrating.
 
I had the exact opposite in high school. We got PE grades for absolute performance. Only problem was that I was 2-3 years younger than the others.
 
That sounds rough, too.
Yay for standardized grading.
 
7:18 PM
0
A: Sandbox for Proposed Challenges

Magic Octopus UrnThe Great Pyramid of Quine The task is a rather simple quine challenge with a twist, you must output your source code in the shape of a pyramid. The shape of a pyramid is defined below: 1 234 56789 ABCDEFG HIJKLMNOP QRSTUVWXYZa bcdefghijklmn ......etc...... The mai...

 
@Adám In my one sole PE class the top student improved their mile from 16 minutes to 6 minutes by walking on the first day
 
@Dennis I'm not disputing whether the answer is valid for OP's phrasing of the question, I'm just curious about the cost of handling zero vs. not handling it. There's unlikely ever to be a second Factorial question in which zero needs to be handled, and it's a rather fundamental problem, so I think it's worth noting in each answer if zero is handled and how it would be best handled.
And I think it's not very interesting to just treat it as an OP's-word-is-law issue where the only thing worth doing is responding to the exact wording of the question. So I'd like to see that 6 byte version please. :) (Saying this here instead of in the answer's comments so as not to turn it into something that's liable to be moved to chat.)
 
@EriktheOutgolfer the 2x1 or 1x2 question is a good one. Since it's ambiguous, maybe I should guarantee the haystack is at least 2x2? That removes the edge case of "only the needle" as well.
Yeah, now that I think about it more, I think I will guarantee it's 2x2 or larger.
 
@AdmBorkBork in reality, you only need to guarantee it's not 1x2 or 2x1 if you want to go like that (well, you can't just assume what the needle is and bring a haystack and whoops, can you? :P)
for 1x1, we know what the needle is perfectly
 
7:33 PM
Yeah, it just seems like a needless edge case.
 
but... yeah, now that I think of it again
well, if you give me a 1x1, better reconsider your entire ability to use that stuff in your head
 
Here's a 1x1, I can't find the needle.
 
@Deadcode o2 (OR 2) at the start replaces 0 with 2.
 
@Dennis o2Œ?IE you mean? It doesn't seem to be working... still returns 1 for input 0.
 
@AdmBorkBork that looks like a pineapple to me...
 
7:45 PM
it's UK tax return day, so CMC: given a string, decide whether it's a UTR, which is 10 digits, either preceeded or suffixed with 'K'
(but not both)
 
@Deadcode Because 2 is a factorial. ._. I meant to write o4.
 
@EriktheOutgolfer I'm guessing "Unique Taxpayer Reference" number.
 
I mean... I assume "which is 10 digits, either preceeded or suffixed with 'K'" is the whole definition, unless @Neil missed something
 
@Dennis Ah, cool. Thank you. :)
 
7:50 PM
@EriktheOutgolfer No, IIRC there's a checksum incorporated into it somehow.
I could be wrong, I'm not native to the UK
 
yeah, that's why I pinged him :P
 
8:08 PM
@Neil QuadR, 14 bytes Try it online!:
⍵≡,'K'
\d{10}
(has trailing newline)
 
8:24 PM
CMC: Given a list of ten integers in the range [0,9] answer whether they constitute valid digits of a UTR per the above formula.
 
@Adám um... the above formula is for obtaining a check character, not for checking the validity
 
@EriktheOutgolfer Yes, so you take the last nine, compute the check digit, and compare that to the first digit.
 
@Adám wasn't there a similar challenge for ISBN-13 before?
 
@EriktheOutgolfer I think so.
 
8:32 PM
@EriktheOutgolfer Quite an old one.
 
@AdmBorkBork oh so that old
 
@Adám huh, the site I read said the K could be at the start or the end
 
@Neil Clearly the governments own code disagrees.
 
8:40 PM
yeah, shame the site I read it from was the site the govermment runs to allow you to pay your tax bill
 
@Neil Clearly, the people dealing with this have no idea what they are dealing with. They refused to the request for information on the algorithm when 1) it was actually publicly available, 2) it has no security impact as it is just a check digit to avoid typos.
 
hello!
 
9:15 PM
@Anush Hello!
Does anyone know whether there's a pretty fast machine instruction to get the "n" where 1<<n is the highest bit of an (unsigned) integer?
Aka Python's int.bit_length().
 
So... Log? (kinda)
 
@DJMcMayhem Yeah. The floor of log2.
 
@wizzwizz4 I am sure there is a bit twiddly trick
 
more like floor(log₂x)
 
9:19 PM
@Adám Boss man at work is wondering if it'd be a good WPM replacement so he tasked me with looking into it
 
@wizzwizz4 that link has methods that take < 10 instructions
 
@Anush Thanks! That looks promising.
 
@Veskah WPM?
 
@wizzwizz4 I think their solutions are pretty much as fast as you get. 32 or 64 bit?
 
@Anush Arbitrary bit, preferably.
It's frustrating because it's something that could be done directly by a CPU.
 
9:21 PM
@Adám Website Performance Monitor, synthetic transaction to test a site
 
Like popcount.
 
@wizzwizz4 doesn't the thing you are taking of log of have a type?
 
@Anush Not yet.
Haven't written the code yet!
 
"In just a few CPU instructions, the truncated base 2 logarithm of any integer can be computed for any integer from -2^63 … 2^63 – 1. This has interesting applications in being able to rapidly access logarithmically increasing arrays. The Linux GCC compiler provides a built in function, __builtin_clzll, to allow this CPU instruction to be used directly from C and C++ on a 64 bit integer.

"
 
I'm just trying to work out whether to use a variable-length loop or a constant-length check.
 
9:23 PM
I think you are meant to use __builtin_clzll
 
@Anush __builtin_clzll is perfect, thanks!
 
and the compiler can work it out for you
 
Luckily I'm on a GCC system.
 
my pleasure :)
 
@Veskah My experience with Selenium was mixed. It was certainly very neat and reasonably easy to learn, but often the interactions were not quite precise enough so I'd have to build in multiple tries and/or offsets, and worst of all, Chrome's side of things tended to change from version to version, requiring adjustments of my code too often. It may of course have settled in the last couple of years.
 
9:26 PM
I think that means there is a cpu instruction
 
@Anush Yes; if there's one available, which there is for my x86, GCC will compile to use that.
 
@Adám I see, I also work on the monitoring side and Selenium seems much more Web Devy in nature
 
@wizzwizz4 looking even faster!
what is it for?
maybe we can speed up another part too
 
@Anush A super secret project that I don't want to talk about too much just yet.
I'll let you know once I know whether or not it's a breakthrough.
 
:)
 
9:36 PM
Anyone good with http?
 
9:50 PM
@Poke Yeah, but I won't be around for much longer.
 
10:20 PM
@wizzwizz4 that's ok. I might ping you tomorrow. Running into some interesting behavior with http1.0 vs http1.1 and keeping connections alive through chunked responses, etc
 
 
1 hour later…
11:42 PM
Ayy, helped to overtake Python.
 
11:53 PM
@Veskah In what?
 
5
A: There's a hole in the bottom of the sea

AdmBorkBorkPowerShell, 194 188 185 bytes $a="in the bottom of the sea" $z="hole $a" $b="here's a " echo hole log bump frog wart hair fly flea smile|%{,"T$b$_ $a"*2;$a='io'[$j++-ge1]+"n the $_ $a";"T$b`hole, t$b`hole";"T$b$z "} Try it online! Can't quite seem to catch Python... Basically, sets a few c...

 
Unacceptable, be right back :P
 
;-;
 

« first day (2924 days earlier)      last day (1911 days later) »