« first day (3645 days earlier)      last day (1181 days later) » 

Leo
12:06 AM
@user Ok, I have studied it a bit more and I can understand it now. It's not a rounding problem, the algorithm is incorrect. At each step it takes a number n and looks for a number m>n for which m^2-n^2 is a square number; the problem is that it never checks that n<(m-n), so it finds some triples that should not be in the sequence
 
@Leo Oh, I see.
 
 
3 hours later…
3:26 AM
:O @Razetime is here!
 
hiii
 
TIL dictionaries aren't auto global in python
like lists kinda are
but not dictionaries
 
@Leo yeah, I wanted to check if it was returning the right thing
sadly not
@Leo sure sure
@Leo you meanƒ
I'll be adding a ton of things to the tutorial once the room is unlocked
 
...what
what does that mean
 
@UnrelatedString well you know how if you modify a list variable in a function it changes it globally?
I assumed dictionaries did the same
 
3:37 AM
because list objects are mutable yes
oh like that
wait what
 
def f(l):
	l[3] = 2

g = [1,2,3,4,5,6]
f(g)
Like that
I forgot dictionaries don't act the same way
 
don't you have to use default arguments to oh like that yeah that's what i meant
 
I wanted them to
act like that
but they don't
 
but they do
 
no they dont
dictionaries dont
 
3:38 AM
what is your code
 
@UnrelatedString it's kinda a mess kinda
oh wait maybe exec is screwing up my globals
okay nevermind
 
that's probably wait you're actually using globals, like global globals
 
everyone disregard everything
I never actually set the dictionary in the function
 
i know
the pains of esolang development
 
3:42 AM
laughs in hasn't finished writing the basic parser
 
cries in having to manually update the online interpreter every time I change the offline interpreter
 
3:53 AM
Should I start an email with Hi! or Hello!? I've been sitting here for five minutes trying to decide.
 
Question 1: Who is the recepient?
 
A teacher who's really chill/informal
 
Hmmm
Hello there, <teacher>
That's probably appropriate here
 
Eh, to me that sounds odd. Might be a regional thing.
 
Hello then
 
3:57 AM
I think Hello! is probably the optimal version, yeah
 
Hello, <teacher>
 
@user @Leo Try it online!
now it works
with the algorithm from the Jelly answer
 
Dah now I can't remember if I allow lambas to take named arguments.
 
same size :(
@Leo @user the question
 
@Leo assuming you mean this room, done
 
4:05 AM
Nov 16 '20 at 17:00, by Razetime
Nov 4 at 3:29, by Bubbler
(Super) Nice-to-have: active mods
 
yes that's right
 
Leo
@HyperNeutrino Thank you!
 
5:11 AM
@Razetime Great!
Is it alright if answers time put before n=10?
 
I can say it's an infinite list and needs to be taken from
 
Because I was really proud of my 18-byter, but it’s too slow to compute the sixth element
 
go ahead and post it
 
Yep, doing that now
 
5:25 AM
CMC: Find decreasing and increasing runs in an array and reverse each run (whichever run comes first takes precedence)
 
5:57 AM
@user somehow both of these don't seem to work right:Try it online!, Try it online!
 
 
3 hours later…
9:05 AM
@Lyxal Ah, General Kenobi Redwolf
 
10:05 AM
I want to repost this question: codegolf.stackexchange.com/questions/136834/…
with attribution
good idea or no?
This is the one that needs to be credited: geeksforgeeks.org/search-a-word-in-a-2d-grid-of-characters
 
I don't really see how that needs attribution. It's a pretty generic word search challenge, it's entirely possible (and reasonable) to just come up with that challenge idea by yourself
 
@Razetime Borderline dupe as it's the same task, only with fewer grid rotations. So I guess no.
 
cool, thanks
 
ngn
@Razetime i agree with caird, this is a common type of word puzzle
 
yeah it doesn't make sense to close it
 
10:14 AM
My guess is that Dennis found a page where it was Ctrl-C, Ctrl-V'ed from and closed it
 
yeah I found it too
it's on some github repo
 
10:32 AM
@cairdcoinheringaahing I expected someone to say that
 
 
3 hours later…
1:18 PM
0
A: Sandbox for Proposed Challenges

pxegerCosmic ray hacking code-golf cops-and-robbers kolmogorov-complexity atomic-code-golf Cosmic background radiation can cause random bit flips in electronics. For this reason, some mission-critical computers undergo radiation hardening. Your task is to use your magic bit flip gun to hack in to a pro...

 
2:05 PM
1
Q: source for a downloadable dictionary with IPA phonetic transcriptions?

Michael SternI have an idea for a fun challenge but it will require access to IPA phonetic transcriptions (in English at least). An API that serves up the same would also do, though it would tend to favor languages with integrated support for external APIs. Web searching has not revealed any such dictionaries...

 
2:21 PM
We need more nominations for Best of CGCC, currently there's 3 categories without any nominations, and 6 with just 1.
5
 
This question is probably going to have the best tips answers
 
I quite like Luis Mendo's and Zgarb's answers to that.
 
I think I'll nominate at least one answer from that challenge
Were you going to nominate both of those, or can we each nominate one?
@user ^
 
I guess we can each nominate one
You can go first
 
I'll nominate Zgarb's, I guess.
 
2:34 PM
Alright, I'll take Luis Mendo's
I don't want there to be conflicts, so I'll wait a while
 
@user Done
 
@RedwolfPrograms Thanks, just finished my nomination
By the way, could you star this message so more people write nominations?
 
2:51 PM
Done
 
Thanks
 
3:25 PM
I finally found those R answers I was looking for. Not as much back-and-forth as I'd remembered, but it's good enough.
 
3:37 PM
All that we need now are some underappreciated challenges.
 
Those are the hardest to find.
Luckily, all my answers are underappreciated, so you can nominate any of them (or all of them) :P
 
I think for the two underappreciated categories self nomination is the best way to find them, but it's also the category that's probably hardest to nominate yourself in
 
Perhaps late answers to old questions might yield some results. I'll try composing an SEDE query later.
 
Underappreciated challenges is the one without any nominations
 
Oh, you're right.
How about this filter?
 
3:52 PM
Oh, that's useful. Is there any way to filter by date?
 
Yeah, you can do created:start..end, I think. Here's the help page on that.
 
This should be a good query
Most good challenges get 15 votes and 10 answers (or more), so limiting it at those should find the ones that went under the radar
@user Planning on going through all answers to my questions this year and looking for gems :P
 
How about Deserialize a binary tree breadth-first? Seems like a good challenge, but only two answers.
I just noticed, that's one of @user's challenges :p
 
4:09 PM
CMC: Answer a challenge with a question id < 1000 (i.e. an old challenge) as the winning answer (i.e. shorter than all existing answers)
This is the latest valid question to ^ (these questions)
 
@RedwolfPrograms While it is of course one of the great challenges ever in the world because I made it, it's not that deserving of more appreciation. I've seen good challenges where the author worked really hard on them, more than I did on this one.
 
0
A: Sandbox for Proposed Challenges

userPeano arithmetic at compile time scala code-golf Peano numbers represent nonnegative integers as zero or successors of other Peano numbers. Task Implement the following operations on Peano numbers, at compile time, in Scala: Addition Subtraction - You will never be required to subtract a greater...

 
4:27 PM
The golfing language I'm designing will be able to do FizzBuzz in 15 bytes (with Fizz and Buzz as 2 bytes each)
 
@RedwolfPrograms Don't tell Lyxal, they're so proud of their 18 byte Vyxal answer :P
 
My language is going to have a sort of ternary operator, but with three options. That's what allows it to work.
I guess you'd call it a quaternary operator, sort of
 
As in if(x % 3 == 1) then A elseif(x % 3 == 2) then B else C?
 
Pretty much, yes, but replace the conditions with x % 3 == 0 and x % 5 == 0
 
@RedwolfPrograms So it's specifically 3 and 5, or what's the general syntax?
 
4:37 PM
There's an operator that takes two functions and makes an array from their outputs on the same input, so I use that on the functions for is-divisble-by-three and is-divisible-by-five, then the quaternary operator uses that
So [false, false] would run the else, [false, true] would run the second if, [true, true] would run both ifs, etc
 
5:33 PM
 
@user "This does not have anything to do with Joseph McCarthy or communism" idk, sounds like you want to flush out them dirty commies to me :P
 
@cairdcoinheringaahing I swear this has nothing to do with exterminating those durn commies hiding in our government.
Btw if you have anything on them, please call 1-800-COMMIES.
 
I'm Gen-Z, I don't call numbers :P And I don't like phone calls, so that's communism :P
 
@cairdcoinheringaahing You don't call numbers? That sounds like red talk to me. You one of them, huh?
 
@user Nah, communism's too played out, anarcho-authoritarianism's the hot shit now :P
 
5:44 PM
@cairdcoinheringaahing Oh, God, they've gone beyond even communism now! What is the world coming to?
 
I'm one of those moderately extremist leftist right wingers who support an economic policy of megacorporation-controlled socialism
 
I say we burn all these radicals, starting with @cairdcoinheringaahing! Who's with me?
@RedwolfPrograms Too many words. Sounds like communism again. Don't tell me you're one of them too.
 
No, I prefer to be oppressed by large corporations
 
@RedwolfPrograms I mean, I've had conversations with someone who says more or less "It bad when government does things, but if a mega-corporation does the same things, it's good" i.e. I don't want Obamacare, I want Bezoscare included in my Amazon Prime membership
 
They'd love Atlas Shrugged.
 
5:48 PM
I think in theory no economic system is really better than any others, although in practice some definitely are
 
@RedwolfPrograms If you're talking about the mainstream ones, yeah, in theory, they might all work about the same, but there are some out there that just sound like nonsense.
 
Well yeah, I'm mainly talking about the ones people've actually attempted to use, I'm sure there are plenty that would be absolutely awful
 
@RedwolfPrograms Technically, we could live without an economic model, as it's all based in something we arbitrarily give value to. But we choose otherwise
 
As for systems of government, I think I have an idea for one that would work better than most of the modern ones, but the implementation would be near impossible.
 
I don't think humans could live like that. Sure, some would be just fine, but others would just go back to trading and bartering.
 
5:51 PM
@RedwolfPrograms "Ok, so the premise is that exactly one person each day is allowed to spend money, and that person changes each day, determined by whoever is winning in an ongoing guinea pig race. Once you're chosen, your guinea pigs goes back to the start"
 
@RedwolfPrograms Stop whatever you're thinking right now. This is how communism starts.
 
Maybe the real communism is the comrades we've starved along the way
 
Thank you.
@RedwolfPrograms By the way, what was your idea?
 
It's hard to write a glowing nomination for someone called "Dingus" :P
 
@user Basically anybody can propose a bill. It doesn't have to be at all formal. Then, for a little while, people can make arguments for and against it and propose changes. Over time these will be merged and/or cleaned up until there is a bill that is well specified enough to be a law, then a sort of jury will review the arguments for and against it and decide whether it should be ratified.
 
5:57 PM
@cairdcoinheringaahing ? How does their name change their accomplishments? You can just ignore it and say "they."
@RedwolfPrograms This is going to be hard to implement on a bigger level (which you did mention). Also, you might want a board to make quick decisions in times of crisis.
But yeah, a democracy like that would be really good.
 
@user "Dingus" (at least where I grew up) is used as a mild insult for someone who isn't too bright. Obviously the user isn't (hence the nomination), but it's a bit like writing it for someone with the username "fool"
@RedwolfPrograms The issue there is that the existence of a "jury" gives extra power to people in a system that's clearly designed so that people have as much equal power as possible
 
@cairdcoinheringaahing Ah, I see. If it helps, I don't think a lot of people know that (I didn't, at least).
But it could work without the jury.
 
@user Oh, I don't expect people to vote differently based on a username (and I hope that's the case) but I do kinda chuckle a bit when writing "Dingus wrote some truly great answers" :P
@user Then all it takes for a populist to take power and the entire system will be reformed to favour them
 
@cairdcoinheringaahing Supermajorities could be required for major changes.
 
Any system that allows to populist to easily take power is not a stable system, because such politicians are never interested in the good of the people/nation, but instead their own interests
 
6:03 PM
I think a jury of somewhat-qualified people works better than a popular vote, as they could research the topic in much more depth and would be more resistant to emotional bias
 
That was the original point of the Electoral College in the US - to prevent the election of a populist - but that's been corrupted over the past 250 years
 
We're going to need to wait until everyone's got access to a computer - then participatory democracy would be a lot easier.
 
@RedwolfPrograms Something like the supreme court? If so, it falls victim to the partisanship issue that the US Supreme Court currently has
 
No, just something like an approval process
 
There's a tradeoff between checks and efficiency. If you have more checks, it gets pretty slow, if you don't have a lot of checks to make it fast, radical changes may be made.
 
6:06 PM
I think this system is much more adaptable for different speeds. If you need a bill passed quickly that very few people disagree with, it will happen quickly.
Whereas important and controversial issues that don't need to be immediately resolved could have years of debate and research, maybe multiple juries, etc.
 
I'm still not totally clear on how that would work, but I guess it could.
Of course, it's unlikely any country is going to overhaul its constitution and laws and organization, and new countries are rare these days, so reforming the governments we have bit by bit seems like the only way to make progress.
 
@RedwolfPrograms I do the appeal of such a system, and it does work in smaller groups. Some key issues tho: it'd require near-constant involvement in the political sphere, or else it becomes easy for a populist dictator to gain a supermajority by just encouraging their opponents that "politics is boring" while their supporters get more and more involved. The jury falls victim to accusations of "elitism" ("why do they get more power?" etc.) and either (cont).
(cont). the voting base votes to remove them (which doesn't look good if that's shot down by the jury) or the jury gets elevated to a much stronger legislative process that just develops into a parliamentary system over time. It'd be far too easy for a populist to gain power by running on a platform of "get rid of the jury, give power back to the people", then once they have power, never relinquish it. (cont).
(cont). Eventually, not everyone will want to be involved in proposing a bill, and will instead ask people they trust to do it for them, leading to a parliamentary system
The reason most countries use parliamentary systems or similar is because most of the time, they work
 
The point of the iterative sort of process is that it doesn't take much work at all to propose something.
A populist wouldn't be able to remove the jury, because which side is more popular doesn't affect which side wins, so unless the populist could make a really good case for why removing the jury would be better it wouldn't work
 
@RedwolfPrograms Populists don't need to make good arguments, that's the entire danger of them. This hypothetical leader (who wouldn't have any actual leadership position aside from a majority of people agreeing with what they say and then voting for the bills that do that) would simply say "the jury is bad, this is a bill to get rid of them" and if they had enough support, the jury would be removed.
 
But there is no popular voting. Just arguments and counter-arguments.
 
6:18 PM
So someone proposes a bill, people debate it, then this jury either approves or rejects it based on the debate?
 
It doesn't matter if 80% of the country supported it, if they can't come up with a good reason they don't win.
 
@cairdcoinheringaahing If the jury can only be removed with, say, 75% of the popular vote, it's unlikely a populist will be able to do that. People can be swayed like that, but not so many.
 
@cairdcoinheringaahing Basically, but with some extra steps
 
Then the jury is overpowered, right?
 
@RedwolfPrograms Sorry but that sounds so bad. That makes this jury basically all powerful
 
6:20 PM
I see no need for a jury. Just have people propose something, have experts refine it and produce different versions of it, and then have people vote on it again (or vote to refine it further).
 
Let's say that through whatever process people got onto this jury, a majority of the jury became old/powerhungry/unwilling to change. The people, tired of this, propose a bill to completely revamp the jury so that it's more reflective of the people's views with near 100% support, and this jury turns around and says "Good arguments. No"
 
But the people voting on it would probably not read the actual arguments. The resulting bill and arguments would probably be thousands of pages of lawyer-speak.
 
> Eventually, not everyone will want to be involved in proposing a bill, and will instead ask people they trust to do it for them, leading to a parliamentary system
 
@cairdcoinheringaahing There wouldn't just be "a jury" made up of some dozen people, it'd be probably thousands or tens of thousands
 
@RedwolfPrograms So Congress but with more people?
 
6:22 PM
No. Basically just a small-ish percentage of normal people.
And only a small pool of them would rule on any particular bill.
 
Surely a system like the current US Congressional system, but where anyone can fill out a form to their representative to request a bill be filed to do something would be a better version of this?
 
Even if the position started out as "normal people", they would later be regarded as being a lot higher up, at least informally.
 
I'd imagine they'd be pretty normal people. You don't regard someone as a higher up just because they were in a jury that ruled on an important court case, right?
 
@cairdcoinheringaahing Without a Senate, with more representatives, and less gerrymandering.
@RedwolfPrograms But in this case, they're not being replaced, right? Or are they?
 
@user Well, gerrymandering would be much worse in this system
 
6:25 PM
Yes, they'd just be some people picked out of a pool of maybe 5% of the population.
 
@RedwolfPrograms And would they be rotated?
 
"I don't like my neighbour, and he doesn't like you. Could you change the district to remove them?"
 
Probably more like picked out of a hat
 
@RedwolfPrograms No, but someone who ruled on the OJ case wouldn't get to determine if black people have the same rights as white people
People with the power to regulate people's lives must be accountable someway, and just randomly choosing these people is not a way to hold them accountable
 
I'd think they'd be required to write a paper on why they picked what they did, and "I don't like this law" wouldn't really hold up. Ideally the arguments would be at the point where a typical person could tell which side should win just by reading them.
It's not like they'd just hear the proposal and some arguments and decide; they'd see the product of months or years of refinement into a few core arguments for each side.
 
6:28 PM
@RedwolfPrograms Just making them write arguments on paper isn't enough though. They could say "Just cos" and you have no way of doing anything.
 
@RedwolfPrograms Unfortunately, that falls victim to the fact that most laws aren't about easily understood things. Without e.g. food regulation, many people get sick or die, but the typical person knows barely anything about how beef is treated, or if one chemical is ok and others aren't
 
That might be fixed somewhat with something like trials in the US Congress where experts testify.
 
@cairdcoinheringaahing That's why the arguments would be clarified and expanded on by experts. Ideally they'd be at the point where a typical person could understand them.
 
Sure, most people can make an argument on whether abortion should be legal or not, but your average Joe won't be able to tell you if you should ban chemical X or Y, even if an expert went "X is good, Y is poison"
 
Like I said, the implementation would be complicated. But I think if it was done right it could be better than a lot of current systems.
 
6:31 PM
@RedwolfPrograms We literally have thousands of experts world wide saying things such as "Abortion is perfectly safe, and helps save lives", "Guns kill people if in the wrong hands", "Global warming is real", yet millions of people choose to just ignore them
@RedwolfPrograms I think it'd work if people were perfectly logical and fully engaged in the political process. Unfortunately, that isn't the case, so we choose people who are (at least in our opinions)
 
Well, I guess the education industry needs better funding first.
 
The main advantage of this is that if you don't know or care about an issue, you just don't submit an argument. If you do know a reason for or against it, you can argue against it or provide evidence of why other arguments are wrong.
 
@user I hope we can all agree on that
@RedwolfPrograms I do like that aspect of it. I know it seems a bit like I'm just shitting on your idea, but there are some real merits of such a system
I do like looking at how things can fail tho :P
 
So do I, I hadn't focused much on the jury part since I'd assumed it'd just be cleaned up later and turned into something workable :p
 
I think the main issue of it is that is falls too easily into Just Another Parliamentary System, as people get disillusioned with the system and realise that politics is and should be boring
 
6:36 PM
It's the central proposal/argument process that I think is the main draw of this system. In theory it's compatible with any type of government I guess.
 
Here's another idea for a political system: Two countries with identical governments, each government checks the other's system.
 
@RedwolfPrograms Adapting a system such as the US so that there was more input from the voters would be the best way I reckon
 
@RedwolfPrograms Participatory democracy is certainly a good idea, though, just somewhat infeasible on a large scale (at least right now).
 
Something such as "Free-for-All Friday", where anyone can book a 30 minute session to propose a bill at the House
Or "Free-for-All Jan 6th" where you can just show up without an appointment :P
2
 
I'm gonna repost this because of the huge conversation here: Any feedback?
 
6:41 PM
starts talking about communism again :P
 
Please, not again
 
@user Unfortunately, I'm not familiar with the topic to provide any good feedback :(
 
Oh ok. Hopefully there are Lisp people here (I myself have never used Lisp, just found M-expressions interesting)
Honestly, Sexprs seem better than Mexprs - they're more regular, and code looks like data.
With Mexprs, you can't easily embed code in your program (as far as I can tell).
 
CMC Given short string input, output the number of hits from a google search.
 
6:58 PM
does Google allow automated access?
(except from Siri)
 
A complicated solution could use Selenium to search something, then find the element that says how many results there were.
 
Are we talking total results, or just on the first page? Cause no-one goes past the first page :P
 
The total results. And I mean actual total results. Not Google's initial guess.
 
7:27 PM
0
Q: Largest Error Message in 100 bytes

someoneThe goal is to raise the error message with the most bytes! The error message may not be generated by the program itself, such as Python's raise. here is an example in python that raises 243041 bytes of error code: def a(m): try:-'' except: if m>0: a(m-1) else:...

 
 
1 hour later…
8:56 PM
120
Q: Largest Number Printable

VereosYour goal is to write a program that prints a number. The bigger the number, the more points you'll get. But be careful! Code length is both limited and heavily weighted in the scoring function. Your printed number will be divided by the cube of the number of bytes you used for your solution. So...

I wrote up an answer to that question, then realized using digits isn't allowed :(
I was really hoping to use my Conway chained arrow evaluator.
 
@user One advantage that the newer question has is: no time restrictions :P
 
@cairdcoinheringaahing The error message one? I thought the largest number one didn't have that restriction either.
 
@user I was thinking more about the largest in 10 bytes one that has the restriction
Plus, 100 bytes is a lot to work with :P
 
For golfing languages, yeah, it's great
Other languages will need it, though
Time to repost the largest numbers challenge without any restrictions.
 
9:46 PM
> For convenience, we'll say \$t = {2^{32}} ^ {2^{32}}\$
That's never something I thought I'd type
 
10:04 PM
@RedwolfPrograms applying that level of built in minds actually 16
There's 2 byte constants for Fizz and Buzz
So don't expect me to go down without a fight
 
10:59 PM
I tried playing an old text based adventure game, meant to lower a rope down and accidentally threw it over the edge of a cliff. I'm smart.
 
@rak1507 Agreed, barring one exception: I do kinda want the site to have a “Biggest number in 100 bytes” challenge, where the only restriction is that it must finish within a finite, measurable amount of time. All the restrictions on “no digits/power/constants” is what ruins them
 
I'd say it should also have to be deterministic
 
11:17 PM
@cairdcoinheringaahing measurable as in it terminates quickly enough to display?
 
@rak1507 No, measurable as in, you could calculate reasonably how long it would take to finish, even if that was billions of years
 
oh right fair enough
why must it be measurable if it is finite?
 
At least I don't see how an answer could go significantly higher than the answers already given
 
@rak1507 they more or less imply the same thing, so I guess it doesn’t.
 
yeah
 
11:23 PM
@Bubbler Maybe not in languages like Perl, but I would have a huge answer in Jelly if I could use constants, digits and powers
 
that is a snoozefest
any interesting ways of generating large numbers have already been done in that challenge
 
0
A: Sandbox for Proposed Challenges

Sumner18Four is Cosmic Four is the only self-referential number in the English language. No other positive number has an equivalent number of letters in its name. This made for a fun game my friends and I would play when we wanted to mess with some people. We called this game Four is Cosmic! How to play:...

 
11:38 PM
@rak1507 Idk, I haven't seen anything similar to this in any of the challenges
 
repeating some builtins over and over is not very interesting to me
 
Well, up arrow is significantly slower than some of the largest numbers in the LNP challenge
(LNP = Largest Number Printable)
I'm pretty sure it won't go into top 5
 
@Bubbler Yeah, I never really understood FGH, but its fun messing around with big (to me) numbers
 

« first day (3645 days earlier)      last day (1181 days later) »