« first day (2893 days earlier)      last day (1941 days later) » 
00:00 - 21:0021:00 - 00:00

12:46 AM
@Neil Agreed, last year I got many hats without trying to - this year I haven't gotten any without trying to
 
Anonymous
@Quintec I've gotten 5, and I've actually put effort towards getting hats. A lot of the hats are tied to badges, which means it's hard to get them on sites where you already have a lot of rep/badges.
 
I've gotten 4 not counting still fresh(where trusted user rep counts for some reason) and the one to view SO's team page. 1 silver badge from chat, 2 top hats for answering, and 1 for answering where I'm a new contributor.
I still haven't figured out the retro fan hat though
 
Anonymous
@Quintec spoilers
 
...oh
 
1:06 AM
@DJMcMayhem Since no one took me up, Python 3, 59 bytes: Try it online!
 
1:50 AM
anyone good with Groovy here?
 
whats up
 
what's this replying to
 
2:37 AM
@ASCII-only depends
 
 
1 hour later…
3:49 AM
@Οurous do you know if Clean has an SVG logo available?
 
 
1 hour later…
5:11 AM
@Downgoat not off the top of my head but I will investigate over the next day or so.
 
5:29 AM
@ASCII-only you wanted groovy help
 
6:00 AM
@quartata oh yeah. are there any cast to int hacks or something? or alternative closure syntaxes
oh. the most important one: is there something like python's a[:x] (anything shorter than a[0..<x] that is
... goddamnit this guy doesn't log in except to post answers
 
6:15 AM
@ASCII-only as int?
dont know what you mean exactly but
@ASCII-only .take(x) is longer by a byte
so i dont think so
 
@quartata i mean shorter than that. i guess not
 
no i know
i was just saying the other idiomatic way i knew
oh you meant as int
theres also .trunc() but thats not likely to be shorter
that returns another float actually. forgot.
so its like floor
 
>_> oops. i meant string -> int
anyway. time to move on to the scala one
 
oh
i just assumed
subtract on string acts like set difference
so no weird JS coercion if thats what you were looking for
its like a normal collection
 
also. is replaceAll with closure a groovy thing only :/
 
 
2 hours later…
8:02 AM
0
A: Sandbox for Proposed Challenges

digEmAllHow many consecutive descending numbers in my number ? 2019 is coming and probably eveyone has noticed the peculiarity of this number : it's in fact composed by two sub-numbers (20 and 19) representing a sequence of consecutive descending numbers. Challenge Given a number x, return the length ...

 
 
2 hours later…
10:21 AM
0
Q: All the digisibles

mdahmouneA natural number (written in the decimal base) is qualified as digisible if and only if it fulfills the following 3 conditions: no of its digits is zero, all the digits that compose it are different, the number is divisible by all the digits that compose it. The challenge is to output all the...

 
@DJMcMayhem 55 bytes
 
@Neil @DJMcMayhem 49 bytes (Py2)
 
don't you mean a%4?
 
Oh oops
 
11:03 AM
0
A: Sandbox for Proposed Challenges

flawrCheck List for Duplicates code-golf Given a non-empty list of integers, return a truthy value if all entries are unique, and a falsey value of there are duplicate entries (or vice versa). Examples [1,2,3] -> false [1,1,3] -> true [1] -> false [1,3,1,5] -> true META: I couldn't find this as ...

 
11:52 AM
0
Q: Count the contiguous submatrices

AdámMigrated from chat Given two non-empty non-negative integer matrices A and B, answer the number of times A occurs as a contiguous, possibly overlapping, submatrix in B. Examples/Rules 0. There may not be any submatrices A: [[3,1], [1,4]] B: [[1,4], [3,1]] Answer: 0 1. Submatrices must ...

 
Is this an interesting challenge? Given a list of strictly positive integers, return the integer that contributes most to the list's sum. E.g. [3,1,1,1,1,1,1,5,9,2,6,5,3,5,8]5 (as it contributes 15, while 1 occurs more often, it only contributes 6).
 
12:37 PM
0³+1⁸+2⁷+3⁹+4⁶+5⁴+6²+7⁵+8¹+9⁰=2019
1⁴+2⁴+3⁴+5⁴+6⁴=2019
 
Spice it up a bit? Given a matrix of non-negative integers, return the indices/mask/values of unique rows that contribute most to the total sum of elements in the matrix. E.g. [[1,2,3],[2,0,4],[6,3,0],[2,0,4],[6,3,0],[2,0,4]][2,3] or [false,true,true] or [[2,0,4],[6,3,0]]
 
@Adám what does [2,1,1] return?
 
ngn
@Adám k: {&h=|/h:+//'x@=x} for both versions
 
ngn
1:39 PM
 
0
A: Sandbox for Proposed Challenges

l4m2WIP: Shortest JsFuck code for a number JsFuck is a language using only []()!+ to run and express anything in JavaScript. Below is a simplified model of JavaScript to express numbers: Types Number String Boolean (true) Array Functions IEEEdouble(x): Let \$u\$ is the number in \$\{a\cdot ...

 
2:50 PM
@Mr.Xcoder Hm, too trivial apparently. It was mean for feedback, not CMC :-)
 
It's not necessarily "trivial", you know that golfing languages sometimes just have the appropriate tools for the job. That's not the case in Python/Java/C/other mainstream languages because they (1) don't have built-in "group elements of list by" commands (2) don't have built-in "select elements that yield maximal results from list" commands. It's indeed easy-ish but definitely sufficient even for main
That is, if you really intend to post it
 
@Mr.Xcoder I suppose the latter is more interesting, right? Would it make better to bump the number of dimensions even higher, or make it variable?
@LeakyNun Since it isn't a full spec/CMC, I have not decided yet. Could be a) 2 or b) any of 2 or 1 c) [2,1]
 
3:06 PM
@Adám It's not much of a difference in my opinion (e.g. my Pyth answer can be modified by 2 or 3 bytes to make it compatible to the other version), but I'm honestly not a fan of extraneous dimensions. IMO you should stick to the matrix case, but of course the decision is yours
 
@ngn You can remove the & for the second one, no?
 
ngn
@Adám if your spec accepts dicts, yes
i mean, dicts in which the values are booleans
 
@ngn I'm a fan of super flexible I/O, so I'd allow anything that clearly and unambiguously shows which.
 
Got 81 in python with itertools.groupby
81 including import
 
Before all celebrations start and I forget, Happy New Year! I created my account earlier this year, and I've felt really welcome by the community, and I've learned a lot both about golfing, constructing languages, and general programming. Thanks for 2018!
10
 
3:18 PM
5779 chugging along…
 
@betseg For which version?
 
3
 
For the very first version of the challenge and returning one of the elements that fulfil the criteria I have 41 in Python
 
Oh wow
I got worse after not golfing for half a year
 
Hold your horses, I'll post to main…
 
3:21 PM
@betseg Erm but I mean 41 for this one:
3 hours ago, by Adám
Is this an interesting challenge? Given a list of strictly positive integers, return the integer that contributes most to the list's sum. E.g. [3,1,1,1,1,1,1,5,9,2,6,5,3,5,8]5 (as it contributes 15, while 1 occurs more often, it only contributes 6).
I haven't solved the generalization
 
Uh I got 81 for that too yes
 
Ok then, just making sure
But unfortunately this technique cannot be ported with ease to the other version of the challenge :(
 
Same
 
Good title for the matrix version? Most contributing rows?
 
That's good.
 
3:44 PM
Capybaras chilling in a hot yuzu bath in winter is the most soothing scene imaginable, please enjoy https://t.co/Enz3v3oate
 
@Mr.Xcoder ok, got 153 for the latter, sadly not a lambda
 
0
Q: Most contributing rows

AdámGiven a non-empty matrix of non-negative integers, answer which unique rows contribute most to the sum total of elements in the matrix. Answer by any reasonable indication, for example a mask of the unique rows order of appearance (or sort order), or indices (zero- or one- based) of those, or a ...

 
4:01 PM
Damn, the challenge was posted right after I left home :/ and the solution was on my computer... Eh I guess I'll post it tomorrow.
 
@Mr.Xcoder Sorry.
 
You've got nothing to be sorry about
I'll post the pyth one anyway
 
I'm surprised that nobody has answered my previous challenge in APL yet. My shortest solution is short enough to brute-force.
 
I wonder if a Factorio Belt Balancer generator would be an interesting challenge
 
4:23 PM
@Skidsdev Can you elaborate?
 
@Adám I'm writing up a Sandbox post now, it might be a bit too complex, we'll see
 
4:40 PM
@Adám by "appearance/sort order", you mean that the indices can also refer to the sorted list of the input's unique elements (instead of kept in original order)?
 
@EriktheOutgolfer yes. Anything I can do to make that more clear?
 
@Adám so the second test case's output can as well be [1]/[2]
 
@EriktheOutgolfer Ah, right, and the boolean can be [0,1,0].
 
5:07 PM
0
A: Sandbox for Proposed Challenges

BMOCollapsing numbers Couldn't find this on here nor oeis.org.. code-golf, integer, sequence Let's define the a function on natural numbers \$n\$, written as base 10 digits \$d_k\; d_{k-1}\; \dotsc\; d_1\; d_0\$, as follows: As long as there are equal adjacent digits \$d_i\;d_{i-1}\$, replace ...

 
BMO
5:17 PM
Does anyone have a preference on the order of processing for this (^) challenge?
Oh, maybe I could take an additional input flag telling which order to use, that could be interesting..
 
@BMO You mean, starting with the most significant digits rather than least? (vs, say, simultaneous as a third option)
 
BMO
@Draco18s: I didn't consider least to most significant.. only simultaneous and non-simultaneous
<s>(non-simultaneous as most to least significant)</s>
 
Simultaneous might do weird things. I.e. 888 -> 1616
 
BMO
@Draco18s It would be either 168 or 816, depending on the order
So, I guess non-simultaneous would be better?
 
True enough. Just saying that a simultaneous execution could go strangely. In any case, I think left -> right is sensible enough
 
BMO
5:24 PM
Yeah, it could
Not sure if it makes it more interesting or more annoying :S
 
*tries to abuse simultaneous collapse*
sim 1111116 -> 222226 -> 44446 -> 8886 -> 16166 -> 16112 -> 1622 -> 164
(l2r 1111116 -> 2226 -> 426)
Hmm. I think it would still always result in a stable final result. That is, I don't think any cycles exist, but it certainly takes more steps to come to rest.
 
BMO
@Draco18s Damn, didn't even think about cycles
 
IMO, simultaneous is more interesting.
 
BMO
Before I used mod 10 for the sum, so there won't be any, then I changed it and didn't think about it at all
 
It makes it more likely to have a higher complexity class.
 
5:32 PM
I don't think cycles are possible, under any variant. You can't sum two digits to anything other than either a single digit (collapses) or a two-digit number starting with 1 and even.
2
A number of the form 1X where X = 2k will never be unstable with itself (it can't be 11, and even if it could, it collapses to 2, which is 1 digit shorter than what we started with anyway)
 
BMO
@Draco18s True
Neat argument!
@wizzwizz4 Allright, I'll keep it that way, I think. It either makes no big difference (implementation-wise) or it'll be more challenging
 
@BMO <sub>Star it so I can have a hat?</sub>
 
Anyone know if there's a fast way to check the most recent time anything in a directory was created/deleted/modified?
 
@Draco18s Save it for the Sandbox.
Starring for hats should occur in the sandbox only.
 
deleted i think is going to be the hard one
 
5:39 PM
@wizzwizz4 I'm being silly anyway :p
 
@Adám Here you go, I think it's definitely too complex
 
@Draco18s Yeah; that was star-worthy. Just for the record, since there isn't currently a Pinned message about it.
 
BMO
@wizzwizz4 It's not for hats, if the message has good reason to be starred.
 
Hence my being tongue in cheek about it.
 
@Pavel in .NET i've used FileSystemWatchers to accomplish something similar
 
5:42 PM
Simple stat reports changes if a file is removed or added but not modified
 
@Skidsdev tl;dr
 
@Adám fair, I imagine that would be most poeples' reaction were it posted to main
 
happy new year, by the way
 
@Skidsdev agreed. I got down to splitters, started scrolling, and my eyes glazed over
 
there's also the issue of I can't mathematically prove that there's a valid solution for all 256 inputs
 
BMO
5:51 PM
@Draco18s Replace addition by exponentiation: 66 -> 46656 -> 44665656 -> ...
 
0
A: Sandbox for Proposed Challenges

SkidsdevBalance those Belts! code-challenge ascii-art In the game Factorio, you transport items around the map using transport belts. Transport belts are 1x1 tiles, can go in any cardinal direction, and have 2 parallel lanes. You can also use splitters to split a single belt into 2 belts, a splitter is...

 
@BMO Exponentiation and higher order operations (tetration, pentration) all probably have that problem.
due to replacing 2 digits with...significantly more than 2 digits
I was specifically referring to adding the two values
 
@BMO Multiplication's a better idea; it's more interesting.
 
but who knows if it will ever end
hm, yeah, I think it does end
00 → 0, 11 → 1, 22 → 4, 33 → 9, 44 → 16, 55 → 25, 66 → 36, 77 → 49, 88 → 64, 99 → 81
 
6:11 PM
Yep. No x*x value ever results in returning the same digits, except 0 and 1, which all return a single digit (and consume 2)
 
Doesn't mean it will end.
You could have a cyclic grower.
759 -> 3545 -> 152020 -> 610000 -> 60000 -> 0000 -> 000 -> 00 -> 0
Ok, bad example... Oh, wait, multiplying the same together.
 
uh... 759 is already the end
 
@EriktheOutgolfer Whoops.
Never mind; it will always end.
 
;)
 
6:55 PM
CMC: Local offset from UTC.
 
@Adám Python, 8 bytes: lambda:0
Works on my machine.
 
@wizzwizz4 Wat. It has to work whatever the local time zone is.
 
@Adám ()=>System.DateTime.Now-System.DateTime.UtcNow
 
@Pavel That's C#?
 
@Adám PPCG 101: it has to work on at least one configuration
 
7:02 PM
Which on my nachine returns approximatly [-08:00:00.0000340]
@Adám Yes
()=>(System.DateTime.Now-System.DateTime.UtcNow).Hours will get a single number but doesn't work in the stranger half and quarter timezones
 
BMO
@wizzwizz4 Yup, exponentiation is the "simplest"
(unless we count a constant function as simpler)
 
@Adám What's APL?
 
BMO
(constant functions are not very interesting, for this)
 
@Pavel I suppose that's due to to time elapsing between querying Now and UtcNow.
 
Yeah
 
7:04 PM
@Pavel Using .NET: ⎕USING←'System'⋄DateTime.(Now-UtcNow)
 
Can you actually access multiple properties like that? Nice
 
@Pavel APL can stand for Array.
@Pavel If you want it as a two-element list of hours and minutes, you can even do DateTime.(Now-UtcNow).(Hours Minutes).
 
Although you can do that in C# too, kinda. using static System.DateTime; Now-UtcNow
 
You can also use a comma instead of the space.
 
Not the Hours Minutes part though
Mm, I think it would fail when there's a positive offset with the hours off by one? Not sure
Maybe not
Also it's interesting to see that while Dyalog doesn't let you overload operators, it does work when you overload operators on a .NET class
 
7:09 PM
@Pavel Now-UtcNow returns a TimeSpan, which will have the sign applied to each part (Hours, Minutes).
 
Mm, you can also do System.TimeZoneInfo.GetUtcOffset(System.DateTime.Now), which is more precise but not as short
 
(-⎕NEW TimeSpan(3 4 5)).(Hours Minutes) gives ¯3 ¯4
 
System.TimeZoneInfo.Local will get a TimeZone object but not an offset
 
@Pavel The APL functions which are overloaded for .NET types are listed.
@Pavel But the ToString of that includes the offset.
 
On my system its ToString is [America/Los_Angeles]
 
7:13 PM
@Pavel Interesting. I get (UTC+00:00) Dublin, Edinburgh, Lisbon, London
 
I think it's because it uses your native time handler which is different on Linux and Windows
 
@Pavel Ah,
 
I'm not sure though, since .NET wasn't intended for use on non-Windows platforms, it's not documented anywhere
Mm, core and mono have different outputs, too
 
@Pavel What is TimeZoneInfo.Local.BaseUtcOffset?
 
A TimeSpan object, in my case [-08:00:00]
 
7:18 PM
@Pavel That seems to be an answer then, no?
 
Yes
Honestly a bit surprised Dyalog doesn't know about timezones
Without relying on .NET
 
I made a self-modifying programming language!
 
BMO
@MilkyWay90 404
 
nice... 404 commands, that is? :P
 
What's 404 commands?
 
BMO
7:20 PM
@MilkyWay90 Best programmering language
 
when I click the link, a big "404" appears... maybe that indicates the number of commands it has? ;)
 
7:21 PM
You broke GitHub :-/
 
Permission errors?
 
Whaaaaaaa
 
ah, you have to append a dot
markdown's fault
 
^^ that works
 
@Adám you have to append a do to the end
oka you did
 
let's use the sandbox for testing please... :P
 
BMO
@EriktheOutgolfer Did a [github.com/MilkyWay90/…..](actual link) lol
 
7:22 PM
@EriktheOutgolfer We weren't testing.
 
oh, accidents?
 
@EriktheOutgolfer Testing? I thought the sandbox was to test questions, not programming languages
@EriktheOutgolfer Is there a different sandbox?
 

Sandbox

Where you can play with chat features (except flagging) and ch...
for testing the link formats
 
@EriktheOutgolfer Ohhhhh
I just pasted the raw link, though
 
yeah, markdown thought the last dot isn't part of the link
 
7:24 PM
Yeah, chat markdown is all kinds of broken and odd.
 
a.*b* meh, dot products are broken :/
 
My programming language is broken? Oof
 
BMO
I'm always annoyed how <s>strikeout</s> doesn't work..
 
@MilkyWay90 no, I tried to represent the dot product with markdown over there, just to demonstrate how much it sucks :P
 
7:27 PM
I'm annoyed how
<sup> T<sub>e<sup>s<sub>t</sub></sup></sub></sup> doesnt work
oh
 
CMC: Given positive integer n, output all the partitions of {0,1,2,...,n-1} that is stable under i ↦ (i+1)%n
 
@LeakyNun %?
 
mod
i.e. send n-1 back to 0
 
↦?
 
something1 ↦ something2 means send something1 to something2
 
7:29 PM
oh
stable under i ↦ (i+1)%n?
 
BMO
@MilkyWay90 I think you should provide a better README.. I have no idea what M.I.C.G.B.F. is about
 
partitions?
 
BMO
Am I feeding it BF-programs?
 
@BMO Read the code, and yes
 
@Adám could you help me rephrase my CMC in a way that people here would understand...
 
7:31 PM
@LeakyNun Sorry, I'm only just about to complete Geometry
 
BMO
@MilkyWay90 Yes, I fed it some BF and it self-modified it into a Python program with SyntaxErrors
3
 
@LeakyNun so {{},{0}} for n=1 and {{}} otherwise?
 
no
 
BMO
@EriktheOutgolfer {{i}}_{i=1}^{n-1} always works, if I'm not misunderstanding things
 
@LeakyNun I'm afraid not. That would kind-of require me to understand it. Sorry.
 
BMO
7:42 PM
@LeakyNun: Are there even other possibilities?
 
yes
 
@BMO um, what is _?
 
@BMO really? There was syntax errors?
 
sets can't be indexed you know... :P
 
BMO
@EriktheOutgolfer Like in LaTeX
 
7:43 PM
yeah, but that's a set
also... {{i}} is a single-element set, so its only element is {i}
 
@EriktheOutgolfer what he means is {{0},{1},{2},{3},{4}} for n=5
 
BMO
Yes, could also be \bigcup_{i=1}^{n-1} \{ \{i \} \}
@EriktheOutgolfer Union over all those
 
@LeakyNun and how does that satisfy the spec? for example, {1} becomes {2} for n=5, it doesn't remain stable
 
BMO
What @LeakyNun said, I've seen/used that notation quite often
 
well it still becomes {{0},{1},{2},{3},{4}}
 
7:46 PM
oh yeah I thought ^ was set difference for a sec... >_>_<_<
 
but then {{0,1},{2}} is not stable, because it would become {{0},{1,2}}
 
BMO
@MilkyWay90 Yes, the execute(... lines where split by new-lines
 
@BMO Oh
 
BMO
@LeakyNun Yes, so what other possibility other than {{0},{1},{2}} is there?
 
that's part of the CMC to figure out
 
7:47 PM
This may be a wrong room for this question, but would you consider JavaScript a context-free grammar?
 
@BMO did you have to run it 2 times for the syntax error to come up?
 
BMO
@MilkyWay90 Don't think so, can't remember tbh
@MilkyWay90 No, just once. Tested it again
 
@BMO Were there any newlines in your BF program?
 
BMO
@MilkyWay90 I used this
 
@BMO Why are you running with Bash?
 
BMO
7:52 PM
@MilkyWay90 What?
 
@BMO Arggh because of the newlines in the program
@BMO I forgot to filter the newlines out
At the end there was a newline
And did you convert the BF program to the MICGBF program using print("".join([chr("><+-[],.".index(i)+1)for i in input()]))?
 
BMO
@MilkyWay90 No
 
@BMO I'll put in a fix
 
anybody up for contact?
 
8:09 PM
@BMO Okay, fixed
 
8:24 PM
append a dot to the end of the link
https://github.com/MilkyWay90/M.I.C.G.B.F.
All bugs should be fixed
@Riker What was so funny about that?
 
BMO
?
Probably there's a conciser way :S
 
@BMO nice
 
BMO
@LeakyNun It's a nice puzzle
 
thanks
 
BMO
@MilkyWay90 Now it even breaks in the first run?
 
8:39 PM
@BMO How, exactly?
Note: You need to convert BF with print("".join([chr("><+-[],.".index(i)+1)for i in input()])) before you program in MICGBF
@BMO Oh yeah, forgot to put in a closing parenthesis
@BMO Should be fixed now
 
um, you know you don't have to delete a file to edit it right
 
BMO
@MilkyWay90 For some reason I don't quite believe you ^^
 
@EriktheOutgolfer Oh yeah
@BMO And I don't quite believe myself either
 
BMO
@BMO Lol, KeyError: 26
 
@BMO arghhhhhhhhhhhhhhhhhhhhhh
@BMO Fixed that one, what error will come now?
@BMO It- it WORKS
I can't believe it!
 
8:50 PM
@MilkyWay90 flawr has a thing for sneks
 
@Riker Okay
@BMO Did you find any bugs?
 
BMO
@MilkyWay90 Didn't try, sorry. But you can just copy the file in that TIO and try there
I should be going anyways and not debugging other programs..
 
@ETHproductions there's my need to answer challenges so the best way is to go up various user profiles :P (I could've spammed your inbox like hell if I wanted to...)
@EriktheOutgolfer I'll say you don't have to handle that case. (Is there some hat awarded for answering old questions? :p) — ETHproductions 1 min ago
 
I'll admit I was a bit surprised when I opened my account and found 10 notifications :p
 
@BMO I tested, didn't show any bugs. And bye!
 
8:58 PM
10? just from my answers?
 
@ETHproductions lol, I normally get 0-1
 
that isn't supposed to happen... I do have self-restraint, any issues? :P
 
@EriktheOutgolfer 4 of your answers, 5 other answers posted after you by other users (at least one on each challenge, lol) and your comment
 
ah yeah the other 5 might've been me bumping the challenges
also... 4?! did I manage that?
 
I didn't actually see any of your answers just by opening my notifications, they all linked to newer answers
 
00:00 - 21:0021:00 - 00:00

« first day (2893 days earlier)      last day (1941 days later) »