« first day (4644 days earlier)      last day (496 days later) » 

00:11
0
Q: Give the best Chaitin incompleteness bound

Charles WangThis was originally a pure mathematics question, but I think I've got the best chance for an answer here. The Challenge For concreteness, consider Peano Arithmetic (PA). For some language L of your choosing, construct a computer program of length at most N bits in L such that: If it terminates,...

01:00
Sandbox posts last active a week ago: Minimum Escaping open-ended-function
 
3 hours later…
03:42
How is take input (x,y) meaning y-th smallest integer whose answer is x forbidden by default?
04:39
139
A: Loopholes that are forbidden by default

Martin EnderAdding input or rules which weren't explicitly mentioned in the challenge There was recently a case where an answerer claimed Nowhere does it say the program can't (also) ask the user what the [result] is. Adding additional input or new rules, because they haven't been explicitly forbidden...

that sounds like a pretty non-trivial equivalence lol
for discussion on something similar check the recent meta thread about decision-problems versus sequences
05:32
@lyxal Thanks
 
1 hour later…
06:45
CMC: Given a string as input, return how many characters in that string appear in the word "butter". Case insensitive so B and b count as being in the word butter.
Uiua, 16 bytes: /+∊∶"buterBUTER"
the butter part is not really golfable I think
07:04
/+∊∶⊂+32."BUTER" ties
also looking at the docs i like how they use "pervasive" for vectorizing
gets the point across without the risk of confusion with hardware vectorization
that word comes from APL terminology
Never knew New Posts could propose a CMC.
Yeah it's a feature that's been around since mid July
07:19
So it seems SE staff learned about the layoffs via the meta post before even being told personally
Seems that way yeah
Kaba Kun read the meta post in the night, had a (I imagine) very stressful night, then only learned that they where didn't have a job in the morning because they couldn't log in to anything
Oh Kaba Kun == Catija nvm
Yeah :p
Me trying to quickly understand and summarize thousands of discord messages
V2Blast is also no longer CM
07:44
@NewPosts Retina (any version), 9 bytes: Try it online!
@NewPosts Charcoal, 12 bytes: IΣES№bertu↧ι
 
4 hours later…
11:16
CMC: Given a number, convert it to base 6, but the digits are butTer. So like b = 0, u = 1, t = 2, T = 3, e = 4, r = 5
Have another butter related CMC?
@lyxal *cough*
well, the downloader's still running
we're on room 202
25 million messages!!!
11:32
How much storage is the backup using currently?
not sure, lemme check
2.4 gigabytes
which means that the entirety of chat is probably around 5 gigabytes
You could fit the whole thing in your RAM
yup
it's now working on the Velodrome
Are you going to do SO and meta too?
12:20
probably
 
1 hour later…
13:23
@NewPosts Charcoal, 8 bytes: ⍘NbutTer
14:08
0
Q: How many umbrellas to cover the beach?

Wheat WizardYou work at a beach. In the afternoon, the sun gets quite hot and beachgoers want to be shaded. So you put out umbrellas. When you put out umbrellas you want to shade the entire beach, with as few umbrellas as possible. Umbrellas come in many sizes. However, larger umbrellas are susceptible to be...

 
1 hour later…
15:31
0
Q: Expand Emmet HTML Abbreviations

noodle manEmmet is a text-editor and IDE plugin for writing HTML code using much fewer keypresses. You might think of it like a code-golfing HTML preprocessor. Its syntax is based on CSS selectors. Your challenge is to code-golf an implementation of Emmet. Given some Emmet code, output the resulting HTML. ...

 
1 hour later…
16:37
Which languages are good for writing fast code? C, C++, rust, Julia and .....?
Fortran....
Assembly :p
@RydwolfPrograms true .. Any others?
I don't know swift at all for example
Or C#
Probably not C#
@RydwolfPrograms thanks
I feel there must surely be another one
There are so many programming languages out there
I forgot nim!
Maybe rpython?
I wonder if this could be a tips question on main
17:08
@Simd Zig?
CUDA?
I don't think nim compiles directly to machine code
17:26
@mousetail interesting! I don't know that at all
@mousetail is that a language?
Yes, though also there are other langauges that compile to it
@mousetail it's very fast. We used to have fastest-code answers in nim here
In the good old days
The Nim compiler supports mainly two backend families: the C, C++ and Objective-C targets and the JavaScript target. The C like targets creates source files that can be compiled into a library or a final executable.
A level of indirection will typically make it slightly slower since it makes optimization harder
@mousetail is it only fast for GPUs?
@mousetail that would make sense
It's basically C for GPUs
GPUs are faster than CPUs
Though it depends on the challenge if you can effectively use the parelelism
GPUs are also better at floating point operations than integer operations
17:32
@mousetail I thought was much more subtle than that
It's complex
I have seen gpu projects where they failed to speed up the code
They probably couldn't parelelize enough
or had to transfer too much data
Could you do this on a GPU? codegolf.stackexchange.com/q/265857/116117
@mousetail right. That seems a big problem
I wish we had some GPU challenges here
Not easily, because integers and loops of uneven length
17:35
@mousetail right. So really it is not easy for a novice to guess when a GPU will help
@mousetail could you simply run the whole process many times in parallel on a GPU? I am guessing not
My answer already runs it on 8 threads in paralel
I don't understand why it only gets to 4 in that case!
No, in GPU all theads share a state so they must execute the same code as the same time. If one thread takes longer all the others will need to wait before being able to advance to the next step
My answer would get less than 1 without multithreading
17:54
I just remember implementing Kalais method in python/sympy once and I am sure it was a little faster than that
Single threaded because it is python
Maybe my answer is just inefficient then
Have you ran my answer on your PC?
@mousetail I'll do that tomorrow. I have not been able to yet
I am wondering if I can usefully add another bounty
Do you know what "A slightly tighter envelope" means?
18:10
@mousetail wait really?
TIL
@mousetail TlLDR divergent branches r bad
Relatively
i found Futhark to be a really nice lang for GPU stuff
@Seggan looks cool!
18:25
We forgot the mythical mojo!
Mojo is going to be slower than other options
🤣🤣🤣 💯🔥
^^
making performance improvements over python is a pretty low bar lol
gonna set up a bot that sends those emojis every time Mojo is mentioned
19:03
Technically you're not allowed to do that :p
technicalities are merely suggestions
/srs I know, but it'd be funny
19:14
@UnrelatedString that is true!
In principle Fortran should be the fastest of all
Fortran shouldn't be slower than C or rust, they all don't have costly abstractions
@Simd I wouldn't necessarily assume that, since C's used so much more, it might have more invested into optimizations
I do believe the main Fortran back-end is GCC-based tho so maybe they have the same optimizations
I'd expect any language that builds directly to assembly and has few abstractions to be equally fast
I think you're underestimating the importance of optimizations tho
It was ages before C was as fast as handwritten assembly wasn't it
In theory you can always optimize yourself
19:21
isn't that a self-help book?
2
@mousetail Maybe, but there's some stuff you'd never be able to do without an asm macro
Optimizations is more about being able to write more elegant code without worrying about performance than about making already optimized code even faster
E.g., vectorization. SIMD stuff gets massively complicated, and no language I'm aware of has syntax that would allow you to take advantage of even a fraction of that complexity without compiler optimizations
Most languages have intrinsics for that
(which are just assembly with extra steps)
But if you fall back to assembly or intrinsics for individual instructions, I feel like that's kinda cheaty
Sort of like people saying Python is fast because it can call out to C++ code
19:27
I think different opinions are just a different perspective of the same thing
0
Q: Write a proof checker for first order logic

Charles WangThis originally came from Give the best Chaitin incompleteness bound, but I realized that there was a fragment of this problem which still potentially gives a good coding challenge. First Order Logic With Equality First, I will need to fix an encoding of first order formulas ('For all x there exi...

19:56
@RydwolfPrograms it would be really interesting to see benchmarks. I do know Fortran was designed to be optimizable unlike any other mainstream language
@mousetail the problem with C is that it makes it really hard to optimize
It doesn't have opaque pointers
I mean C does have opaque pointers
20:12
@Simd citation for this?
(the part about "unlike any other mainstream language")
@Simd You can use the restrict and const keywords to improve optimization of expressions with pointers a bit, but mostly you have to do it yourself
@Simd Assembly would like a word with you
21:04
@Ginger it was a challenge to name one :)
@Seggan run away!
 
2 hours later…
22:35
CMC: Return the sum of all code-points in a string. Score is the sum of bytes in your solution, lowest wins.
Vyncode is slightly better for 22.
that's an interesting question
how are fracbytes scored?
and then how are logbytes scored?
Also, if outputting as a character with the corresponding chr value is allowed
~Recinded~
I forgor the flag that sums it :skull:
big brian moment
22:47
I've never succeeded in finding a good quine-related challenge so
Fractional bytes are easy, concatenate and re-interpret. Log bytes are designed by the devil.
@ATaco ---strike---
My formatting was not an error, but intentional style.
suuuuure
The world is trapped and only I am free
I can do anything
22:49
you [clown around town]
stop targetting the goat
that's an awfully long-winded way to say "I forgor 💀 how strikethrough works"
23:13
for a second, I missed the l in clock
a very unfortunate typo
os.rooster()
23:30
@lyxal a cock-up
2
23:41
@ATaco Fig, S \$\log_{256}(96)\$ bytes
CM(ega)C: Repeat to fibonacci in Uiua, but without padding and tag built-in function
@ATaco can i assume no null bytes in the string or do i have to account for those
You have to account for them
Lenguage, Score: 0 is an obvious trick
23:47
lol
@thejonymyster You may take the length of the string first if that makes it easier
doesnt make it easier in this case, but reasonable
i have a "check if input is exhausted" thing i was just trying to golf out :P
Headass, 9 bytes, score 752: {N)U^}:DP (strings are list of charcodes)
theres definitely not a shorter answer in bytes but i wonder how low i can reasonably go by using a different construction
𝗖𝗠𝗖: Given 3 strings, return a java header comment with the details filled in. The first string is the file name, the second string is the author name, and the third string is a file description. The template looks like this:

/**
* {𝚏𝚒𝚕𝚎𝙽𝚊𝚖𝚎}
* 𝙰𝚞𝚝𝚑𝚘𝚛: {𝚊𝚞𝚝𝚑𝚘𝚛𝙽𝚊𝚖𝚎}
* 𝙳𝚎𝚜𝚌𝚛𝚒𝚙𝚝𝚒𝚘𝚗: {𝚍𝚎𝚜𝚌𝚛𝚒𝚙𝚝𝚒𝚘𝚗}
* (𝚝𝚑𝚎 𝚍𝚎𝚜𝚌𝚛𝚒𝚙𝚝𝚒𝚘𝚗 𝚖𝚊𝚢 𝚜𝚙𝚊𝚗 𝚖𝚞𝚕𝚝𝚒𝚙𝚕𝚎 𝚕𝚒𝚗𝚎𝚜)
*/
It's funny that this (Not this^^^) particular challenge overly rewards boring solutions.
23:54
thank you for reminding how many answers I wrote for the challenge
hopefully those shouldn't be reversed because I voted on all the answers
I hope so too :P
I had a really clever Swift answer and then a boring defer{thing}// ended up being shorter
Reminds me of when I lost 60 rep on Korean Language SE because serial upvotes were undone. :(
Like compare the short and boring way
var x=0,y=1;defer{print(x)}
(x,y)=(y,x+y)//
vs abusing a parser bug
var x = -1,y=1//"
print(String(repeating:"1",count:y),terminator:"")
(x,y)=(y,x+y)
#if swift(<4)
(#endif
"
23:58
@lyxal speaking of votes, I'm 6.6k votes away from overtaking gnat as the most prolific voter :p
5
a lang as mainstream as swift has a parser bug??
@Bubbler Starting in 4.0 and until it was patched in 5.7, unmatched parentheses inside an inactive #if swift() block may be followed by an ill-formed string literal after the #endif. It's so obscure that probably nobody encountered it for all those years

« first day (4644 days earlier)      last day (496 days later) »