« first day (2393 days earlier)      last day (2465 days later) » 

5:00 PM
What? Javascript BELOW C and Ruby... They've had a headache when they've written that article ≤_≤
Objective-C is there but SWIFT isn't... That's 100% wrong
 
And C is there twice
 
This website might not be the best source of information.
 
> 3. C
 
@officialaimm what mistake
 
5:02 PM
> 10. C
Eugh
 
@ASCII-only The IF ELSE Statement....
 
@Pavel that's a terrible article lol
 
Horrific article, I'd say
 
Java #1 and Python #2. Really?
 
5:04 PM
Better article found:
> SQL #2
o_O
 
Much more relevant.
 
@Pavel yeah there are a lot of databases out there
 
10 mins ago, by ASCII-only
@Pavel eh C# isn't exactly the most widely known language here
According to the StackOverflow survey, it's more well known than Python.
 
@Pavel here being PPCG
 
5:07 PM
I don't think most people here work as programmers, which has a big impact on language usage
 
I'd say of the people here who work at all, most do something programming related
 
I would say java is most well known, then python, then javascript, then sql, then ruby
 
@ASCII-only the one liner IF- else gets executed in MS-Qbasic... It must be that it is a language variation microsoft adopted then!!
 
I'd say: java, javascript, python, c#, sql, ruby, c (++), swift
 
I think more people here know C/++ than Ruby.
 
5:15 PM
On PPCG: Jelly, 05AB1E, Pyth, MATL, charcoal
 
I always get confused with ruby and perl.... which one is python-like again?
 
@officialaimm None of them
 
@Mr.Xcoder I only know 1 of those languages ಠ_ಠ
 
Definitely not perl though
 
And not super well
 
5:16 PM
@BusinessCat I didn't say what we know, just what the most popular are
@BusinessCat I know 2 kinda well and other 2 not so well
 
ruby is python-like
i think the dude who made ruby also said something about it
 
Meh, kinda
 
ruby is python done right
7
 
*python is ruby done right
9
 
He was inspired by Guido
^^
@ConorO'Brien What are the reasons you hate Python so much?
Conor - types endless list
 
5:20 PM
I started typing that list
but I decided to do the inverse
let me tell you all the good thing about python
 
(1) it didn't screw up library imports. (2) generators. (3) named keywords
that's all I can think of
 
@Riker ಠ_ಠ
@ConorO'Brien List comprehension is nice.
 
^
 
@Pavel LCs are generators
 
5:23 PM
it's fine
 
Like, in essence
 
they're just a reiteration (no pun intended) of the for loop
 
yes but it's much neater to write
 
HHAHAAHA
 
@ConorO'Brien I would really add String slicing to that list. It's better than in any other language I know
 
5:25 PM
@Mr.Xcoder I was about to say, how presumptuous >.>
 
foo = [i + 1 for i in list] is much better than foo = []; list.each{|i| foo << i + 1}
 
string slicing is okay, but I find that I hardly ever use it often enough to warrant a dedicated syntax
@Pavel list.map { |e| e + 1 }
 
As you can see I don't know Ruby very well >_>
 
OH and operator overloading, python does that quite nicely
 
5:27 PM
I disagree with that.
 
I agree with Conor
 
I don't like Python's magic methods.
 
Because you probably didn't take the time to understand them
 
Yeah I'm not crazy about the specific implementation of operator overloading
But op overloading is a very useful feature to have
 
@Mr.Xcoder I understand it, I just like the way it's done in C/++/# more.
 
5:28 PM
I like how ruby does it, but it doesn't provide RHS operator overload IIRC
@Pavel operator overloading in C? o_O
 
@ConorO'Brien Now, list a couple of things you really dislike about it
 
@ConorO'Brien Not C
 
oh I've been typing that up for a few minutes
 
Just ++ and #
 
C(++|#)
 
5:29 PM
C(++ || #) :)
 
C(\+\+|#)
 
Mhm, someone should make C**
 
I was thinking C##
 
@Pavel But that's just D
 
Is it?
 
5:32 PM
@MDXF is making C+
 
As far as music is concerned
 
Ah
 
something interesting: multiline messages don't support markdown in chat, but they do on the starboard. see here
 
I thought you were saying that C is to C# as C# is to D, which is wrong.
 
@Riker very interesting
 
5:34 PM
@Mr.Xcoder you have to check if the variable exists and then assign a default, I asked him
 
@LeakyNun yea
hey your avatar changed
 
@StepHen How. Example?
 
it's now a bright blue identicon
idr what it was before but not that
 
in Proton, 22 hours ago, by HyperNeutrino
https://tio.run/##KyjKL8nP@59m@18jUUchyd5eU8HWTiFJIbUis7ikWMFeIVFBG8i1UtA1/F9QlJ‌​lXopGmYaipyQVn6ygYaWr@BwA
oh yeah and ?? means that it can be null
 
That's just optional, doesn't give it a default value
 
5:36 PM
anyhow, here's my nigh endless list (some complaints aren't limited to python, but most are). regex, classes, class inheritance, ternary if-else, indentation via mandatory whitespace, lambdas, lack of type safety, class method declaration, (mainly python 2: confusion between statements and functions), scoping (to be fair I never cared about python enough to learn the specifics of scoping in python), global scope pollution, the weird desire to be partially backwards compatible with python 2, ...
 
31 mins ago, by Pavel
https://insights.stackoverflow.com/survey/2017#technology
 
@StepHen Not what I meant. I wanted the equivalent of lambda a,b=1
 
@Mr.Xcoder yes I know
 
it doesn't exist
 
5:37 PM
Meh
 
closest you'll get is (a, b??) => b = b exists ? b : <default>
I think Hyper said he'll consider adding it though
 
3
Q: Codegolf the sequence of distance-3 Hamming Codewords (A075926)

Jorge PerezCodegolf the hamming code (with distance equals 3)! The sequence looks like this: 0, 7, 25, 30, 42, 45, 51, 52, 75, 76, 82, 85, 97, 102, 120, 127, 385, 390, 408, 415, 427, 428, 434, 437, 458, 461, 467, 468, 480, 487, 505, 510, 642, 645, 667, 668, 680... Task Output the first n hamming codewor...

 
I hope he does
 
this is what he said about it:
in Proton, 22 hours ago, by HyperNeutrino
because I didn't implement that
 
@StepHen It was a matter of outgolfing totallyhuman, so that borky syntax won't help :/ - Thanks for the references!
 
5:40 PM
@Mr.Xcoder Hey, my syntax doesn't have anything to do with this. :p
 
Wow, Physics.SE is a dead place. The last questions have ≈5 views each, although they're >30 mins old
@AdmBorkBork Sorry, no pun intended :P
 
who the bleep flagged python is ruby done right
are you freaking kidding me guys
 
Who flagged that?
 
@Mr.Xcoder more like they get a ton of questions and they don't have enough people to answer them :P
 
@Riker who the hell flagged this
 
5:41 PM
@StepHen Nope, 1 question in 10 mins is the average
Some Ruby lover, prolly
 
@Mr.Xcoder average what, SE-wide?
 
>:(
 
@StepHen No, Physics.SE
 
@Mr.Xcoder ... are you saying that's slow?
 
BTW what's the name of this channel refer to?
 
5:43 PM
@StepHen Yes, compared to SO and M.SE, very slow
 
The bar at the end of a golf course is traditonally called The Nineteenth Hole
 
oh yeah!
 
And we're Code Golfers
 
thanks :)
 
43
A: Let's think of a creative name for our chatroom

dmckeeWell, the traditional generic name for the country club bar is "the nineteenth hole", which suggests The Nineteenth Byte or something like that.

 
5:43 PM
@Almo Apart from that, the thing is that The Nineteenth Byte is exactly 19 bytes long
 
yeah that's really cool
:)
 
@ConorO'Brien ... capital letters in constants such as True, False, None, the weird while...else or for...else constructs that almost no one uses. I think I should do a "programming sins" like "cinema sins", that'd be kind of fun(ny) :P
 
ok point for capital constants
 
@ConorO'Brien wait, you don't like classes?
 
@ConorO'Brien I agree on ternaries and classes.
 
5:45 PM
that's one of the dumbest things of python
 
Also, visiting TNB causes an equal if not greater drop in productivity as visiting a pub.
8
 
and don't you dare perform a sed substitution on my message
 
@totallyhuman s/of/in/
 
@Pavel I'm plenty productive here
 
5:46 PM
@StepHen I love classes. Python is an abomination to classes basically
 
Just what I'm producing is up for debate.
 
:I I kinda like the lack of safety (types)
 
@ConorO'Brien Yes, but it's better than JavaScript...
 
@AdmBorkBork In the same way that visiting a pub makes you produce vomit?
 
@Pavel You know, we're golfing productivity
 
5:46 PM
Sure.
 
ಠ_ಠ magic functions are perfectly done
@StepHen ...ಠ_ಠ
 
@StepHen no, actually, it's not.
because js doesn't have classes
 
@ConorO'Brien well the classes in Python are better than the prototype stuff in JS
which is what I mean
 
Arabic doesn't have the g sound :o
 
As far as I can tell, JavaScript has dictionaries disguised as objects.
 
5:49 PM
^
they don't even hide it :P
 
@LeakyNun :0 Really?
 
@Mr.Xcoder yes
 
Which is why the most common way to serialize a dictionary in any language is as JSON.
 
@Pavel I thought you said classes, my bad
 
in some ways, even classes are objects lel
 
5:51 PM
@totallyhuman yes but they are first functions in JS (and then functions are objects) :P
 
In C#, everything is an object.
 
@LeakyNun g as in grand?? or germany?? There is a throaty sounding equivalent to g(grand) I think..
 
they only reason JavaScript can even simulate classes is closures
 
should I even try talking about javascript
 
@officialaimm the hard g, as in grand.
 
5:52 PM
no pls don't
 
@ConorO'Brien don't get offtopic, one at a time
 
aight, have fun being unenlightened :P
 
i'm afraid your walls of text are some times too much :P
 
In Java, ints, chars, etc. or primitives and not object, however while C# does make the distinction between value types and reference types, it still consideres everything to be either a struct or object.
 
and in JS...
 
5:52 PM
@Pavel in JS ints are floats and floats are objects
 
There is no difference between an int and a struct foo { int a; }
Except the way you get the value.
 
what even is a struct trying to be
 
in short: prototypes are awesome; objects are not dictionaries, they are glorified hash tables; primitives are not objects, and "classes" are objects with prototypes
 
@LeakyNun are you learning arabic?? I like the three-syllable thing in arabic... Do you know about that?
 
@totallyhuman A class that you can pass by value instead of by reference.
@ConorO'Brien Isn't a Dictionary a generalized hash table?
 
5:54 PM
@officialaimm I'm not learning arabic but I have heard of the triliteral roots
 
@Pavel yes
 
So....
 
e.g. k-t-b means everything from book and write to author
 
14
Q: Optimal path through a matrix

Stewie GriffinGiven a matrix consisting of positive integers, output the path with the lowest sum when traversing from the upper left element to the bottom right. You may move vertically, horizontally and diagonally. Note that it's possible to move both up/down, right/left and diagonally to all sides. Example...

 
the difference lies in the vowels
 
5:55 PM
Is it a dupe? ^^
@WheatWizard I disagree. Apart from the mostly superficial differences that this challenge allows for diagonal movement and all positions are reachable, the other challenge requires return of the path itself rather than just the cost of the path. Unless you're using built-ins that return both, the code is not interchangeable. — beaker 1 hour ago
 
(this is why Arabic/Hebrew don't really write out every vowel, because the main meaning is in the consonants)
 
@StewieGriffin IMO it is
 
@officialaimm you see, my messages are split
 
@StewieGriffin I don't think so, output formatting for the other one was weird and probably a lot of the bytes
 
In PowerShell, even number literals are objects.
 
5:56 PM
But I don't have such strong opinions
 
@LeakyNun but Arabic isn't golfy, it's way too many bytes...
 
@StepHen ...
 
@StewieGriffin actually let's close the old one as dupe
 
@StepHen I don't think it's a dupe either, but I'm biased towards my own challenge of course...
 
5:57 PM
Anyone into bitwise stuff? Any shorter way for (1-s), other than -~-s?
 
@StewieGriffin the output format is wonky and it only has one answer, plus it's got an unrelated title
 
@Mr.Xcoder --s maybe? :P
 
@ConorO'Brien Python
 
no, this doesn't even work in C
 
5:58 PM
@ConorO'Brien ಠ_ಠ
 
yeah I know
 
wait what language would that work in o0
 
I thought -~-s looked basically like --s, bad joke :P
 
@ConorO'Brien -~-
 
6:00 PM
@StepHen I don't think it should be closed as a duplicate of mine to be honest, they're not duplicates in my opinion. It's possible the older challenge is not as good as the new one (I won't judge this), but it shouldn't be closed as a dupe as far as I can tell.
 
@StewieGriffin yeah I retracted that vote
 
> The pyramids of Giza were as old to the Ancient Romans as the Ancient Romans are to us. When the Pyramids were being built, there were woolly mammoths living in Wrangel Island.
 
@AdmBorkBork We are very specific (IIRC) with our rules for free flags: They have to be required, and not a "one of these is required, pick one"
but the "pass the size of the cube", while it could be required, it's a "pick one out of many"
 
@NathanMerrill yep, the meta post I found said that if one is required but there are several options, you don't need to count the invocation ( -) but you do need to count the bytes of the flag itself
 
So how does that work with Perl, where you pass in the version?
 
6:06 PM
10
A: Scoring mandatory but varying command-line arguments

Martin EnderThey're evidently part of the program, and they're important information so they should be counted. That said, I'd probably count them as 3 bytes (not 5 as would normally the case when you have to add a space, a hyphen and your three characters to the command-line invocation) since the "standard ...

 
@AdmBorkBork well, future versions always have new releases
I can't just put a future version on a past interpreter and make it work. Therefore, I'd argue that passing the current version is always what you want
while you can pass in old versions, I'd argue that that is no longer "required", and you would need the bytes
As far as unbanning MetaGolfScript, I think you bring up a good point: We either are strict on flags, or we unban metagolfscript. I happen to be on the "strict on flags" party, but I completely understand your side
 
@LeakyNun Can you help me golf a Pyth submission?
 
@Mr.Xcoder sure
 
@LeakyNun I have this: W<lYQ=+ZJ.Em>3/.BxZd\1Y=+Y*-1J]Z)Y (uses a while because I didn't see any other approach)
0
A: Codegolf the sequence of distance-3 Hamming Codewords (A075926)

Mr. XcoderPyth, 34 bytes The algorithm is very similar to the Python answer W<lYQ=+ZJ.Em>3/.BxZd\1Y=+Y*-1J]Z)Y Try it here.

 
@Mr.Xcoder I still haven't worked out the definition of the sequence...
 
6:13 PM
@NathanMerrill Yeah, I get your side, too. I guess I'll wait to see what Martin responds on my comment.
 
Ok, I'll let you figure it out by yourself. I am not entirely sure I understood either, It is kind of a blind port of the Python answer.
Rod saw my golfing suggestion, but didn't edit
>_>
 
@Mr.Xcoder oh I understand it now
 
Great
Let me know if you seek golfing opportunities (you probably will :P)
@LeakyNun o_O Thanks a lot!
 
6:28 PM
Play RPS with in in-browser ANN: tenso.rs/demos/rock-paper-scissors
 
oh nvm
 
It doesn't link it
We had this discussion last week
 
i didn't
:P
 
oh
:P
 
pls halp golf lambda s,p:[sum(p[s.index(i):s.index(i)+s.count(i)])/s.count(i)for i in s]
 
6:36 PM
@totallyhuman What does it do?
 
13
Q: Mario Kart Scoring w/ Ties

geokavelI ran into this problem while working on another challenge I'm making for this site. In that challenge I utilize "Mario Kart 8 Scoring". The amount of points the player in kth place gets is represented by this 1-indexed array: [15,12,10,9,8,7,6,5,4,3,2,1]. So 1st place gets 15 points, 2nd place g...

 
@totallyhuman Just saying, did you see there is a Python solution already, no?
 
@totallyhuman lambda s,p:[sum(p[s.index(i):][:s.count(i)])/s.count(i)for i in s]
 
@LeakyNun ohh that's a good one
@Mr.Xcoder and i just out-golfed it :P
 
6:41 PM
How did I miss that challenge?
@totallyhuman Or Leaky did :P
 
@totallyhuman In fact, it is 1 byte shorter :P
 
in my world, that's an out-golf :P
 
Ok
I thought of a method that might be better... Not Sure though
 
bring it on :P
 
6:44 PM
Wait, working
 
0
A: Mario Kart Scoring w/ Ties

totallyhumanPython 2, 66 bytes -8 bytes thanks to Leaky Nun. lambda s,p:[sum(p[s.index(i):][:s.count(i)])/s.count(i)for i in s] Try it online!

 
@totallyhuman I had this, but dividing by length makes it longer: [sum(p[s.index(i):s[::-1].index(i)])for i in s]
 
ah nice trick
 
@totallyhuman Oh, it doesn't seem to work though
 
just 3 bytes longer thouhg
oh... and that
:P
 
6:47 PM
@totallyhuman lambda s,p:[sum(p[s.index(i):len(s)-s[::-1].index(i)])/s.count(i)for i in s]
 
10 bytes longer
 
I cannot remove len(s) for some reason.... oh
@LeakyNun Do you know how I could golf [blahblah:len(s)-x] to [blahblah:<something>x]?
 
wasn't it -~ or something?
btw, -~- is a great face
 
Oh, 12- works here!
@totallyhuman Dumb me ^
 
@Mr.Xcoder You want the index from the end?
 
6:51 PM
@Mr.Xcoder parentheses
 
Yes
 
@Mr.Xcoder same byte-count though
 
Then ~s
 
@LeakyNun Thanks, I found 12-
Works for the purpose
 
wait, neither works
the middle should be all 7
 
6:51 PM
Why?
@LeakyNun No, you may output as a float.
 
@Mr.Xcoder 7 or 6 or 6.83
not 0.
 
What?
 
@Mr.Xcoder run it yourself
 
@LeakyNun [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1] gives [6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333, 6.833333333333333].
Not sure what you mean
Yours fails.
 
never mind
ignore it
 
6:54 PM
Posted, golfing (hopefully)
 
why doesn't it work without the 12?
 
@LeakyNun Absolutely no idea
 
@Mr.Xcoder because -0 is 0 ^^
 
@LeakyNun :o... right
 

« first day (2393 days earlier)      last day (2465 days later) »