« first day (2524 days earlier)      last day (2304 days later) » 
00:00 - 21:0021:00 - 00:00

12:24 AM
1
Q: Matrix vs. Linear Algebra

Wheat WizardCurrently we have two tags matrix and linear-algebra. These tags have a rather large overlap, in fact (after a clean up) of the 30 questions tagged linear-algebra the following are the questions not tagged with matrix Arnold's Cat Map Self Referential Polynomials Linear Independence Solve a Li...

 
 
3 hours later…
3:24 AM
0
A: Sandbox for Proposed Challenges

SteadyboxSqueeze Out a Square Quine ...the bigger the better. Task Write a full program that is a proper quine (a piece of code that outputs itself without reading its source code). To make things more difficult, your code (and obviously the output) has to be in a form of a square, meaning that your co...

0
A: Sandbox for Proposed Challenges

user202729Golf a return-oriented code generator! Background Return-oriented programming (ROP) is a computer security exploit technique that allows an attacker to execute code in the presence of security defenses such as non-executable memory (W xor X technique) and code signing. (from Wikipedia) Cha...

 
Anonymous
 
@Mego no hopf map :(
 
That was neat and golf relevant.
 
Anonymous
@LeakyNun Be the change you want to see in the world
 
@Mego I know 0 javascript
 
4:45 AM
@LeakyNun I know a negative amount of JS. People around me start forgetting what they know about it
 
I don't know Javascript, don't let anyone tell you otherwise.
 
@LeakyNun What's a hopf map?
 
@Pavel in math terms or no math terms?
 
In whatever terms you were using in that moment
 
how much topology do you know?
 
4:48 AM
Not a lot
A listened to a three hour lecture on it last year
 
so there's a map from S^3 to S^2, where S^2 is the two-dimensional sphere (the usual sphere) that sits inside 3D
and S^3 is the hypersphere
this map has the property that it maps circles to points
i.e. every point is mapped to by a circle
 
Ok, I get it
 
and its animation is cool
 
5:12 AM
How is that related to topology...?
 
oh
the hopf map H:S^3->S^2 is not null-homotopic and generates the 3rd fundamental group of S^2
:P
 
 
1 hour later…
Is the only way to loop in Hexagony is to make a circular (or wraparound) path and let an IP run around it?
 
What other way would there be?
 
 
2 hours later…
8:22 AM
@user202729 well, any path that goes back to the same cell in the same direction really
you could have a bunch of mirrors and wraparounds in the same loop
 
 
1 hour later…
9:23 AM
@Mego -1 repost
 
 
3 hours later…
11:55 AM
0
A: Sandbox for Proposed Challenges

J843136028Areas of Polygons with Vertices of a Polygon Rules Given a list of integer coordinates, l, and an integer n such that n is smaller than the length of l, return the largest area of an n-gon (n-sided polygon) that has all the coordinates of its n vertices in the list l. You will only be expected ...

 
12:21 PM
@ASCII-only I missed it the first time so it was worth the repost from my perspective. Seems at least 7 people agree :)
 
12:39 PM
1
Q: How small can it get?

ArnauldStarting with a positive integer N, find the smallest integer N' which can be computed by repeatedly dividing N by one of its digits (in base-10). Each selected digit must be a divisor of N greater than 1. Example #1 The expected output for N = 230 is N' = 23: Example #2 The expected output...

 
 
1 hour later…
2:01 PM
Does anyone have pre built Hexagony colorer for Windows?
 
2:21 PM
Looks like I have to download source & build... is it Windows compatible?
 
2:34 PM
So now... how am I supposed to use this?
No problem, figured it out. Right click at a position and ...
 
3:04 PM
That feel when you outgolf sb by 6 bytes, then Dennis shows up and outgolfs you by 7... In Jelly. Wow!
 
3:26 PM
Huh... I think means "lower range"? It also have "L" in its name... anyway.
 
If my golf submission is a recursive function and it calls itself (f()), can I still just count the lambda as the score or do I need f=?
 
You need f=.
When you need to redesign a Hexagony program from an early point...
 
4:17 PM
@Mr.Xcoder that's not even 500 miles that's totally doable
that's not even the length of my state
:p
 
@Riker Who travels 700 km to see someone they had never actually met IRL?!
 
@Mr.Xcoder tbh I think a lot of people who travel 700km see people they've never met IRL
seen before online, probably a small fraction but a present fraction of that
 
:-? okay
 
Jon Skeet is probably going to hit 1 million rep on SO sometime in the next couple months.
 
Which is just displayed as 1000k.
 
4:28 PM
citation?
 
306
Q: How to format reputation when Jon Skeet hits 1 million+ rep next year?

BohemianBased on Jon Skeet's past reputation gain, he will hit 1 million some time in July next year. We have until then to decide on how to format his colossal reputation. The choices for the short format of 1234567 are to continue the "k" magnitude: 1,235k Or start an "M" magnitude: 1.235M ...

 
Also, how it's displayed isn't as important as the fact that it's a significant milestone.
Who cares how it's displayed
 
@mbomb007 people who care about how it's displayed?
 
Is it true that < / > is the only "path collapser" and "code branch" (not counting corners)?
(Hexagony)
 
5:09 PM
When do you think Jon Skeet's reputation will hit 1 million?
 
You've said seconds can be skipped some times, but I'm still not clear how often and which seconds can be skipped. — Wheat Wizard 21 hours ago
Since everyone thinks the question is perfectly clear could someone explain to me the answer to my question?
 
5:33 PM
everyone? I'd VTC again if I could
 
Oh it was closed once before.
@Adám @Dennis @Steadybox ^^^?
 
What's with the mass ping?
 
They think the challenge is clear
@Zacharý According to my calculations, between January 15th and 20th, but IMO January 17th
 
Those are the people who reopened it.
 
@Mr.Xcoder I'm just gonna guess a month from Christmas: Jan 25th
 
5:40 PM
His average rep/day in the last month is about 205, so about ((1000000-995626)/205) days. It's the 27th of December (in my timezone), so 27 + ((1000000-995626)/205) ≈ 48.3365853659. December has 31 days, though, so my estimation is ceil/floor(48,3365853659-31) ≈ ceil/floor(17,3365853659)th ≈ 17/18th of December. Can't wait to see
 
Yep, that seems like a good amount of logic that went into it,
 
@Zacharý Well everything depends on Jon Skeet
 
<cringeInducingMeme> You are everything, Jon Skeet. </cringeInducingMeme>
 
@Mr.Xcoder You mean January? :P
 
... never noticed that.
 
5:44 PM
Ah crap. Yeah got it right in my first comment: January 15th and 20th, but IMO January 17th
 
@WheatWizard I don't understand what's so unclear. You may sleep 1 even if it will eventually lead to a skipped time stamp.
 
Besides the obvious "What is a sleep?", this only solves the problem if your language has a builtin sleep function. When can languages without a sleep skip seconds?
 
@dzaima Jelly, 12 bytes “C1ġ¹)ʂ°BƲ » Ninja'd :(
 
Also "You may use sleep(1) even if a specific second may occasionally be skipped." still doesn't tell me what "occasionally" means
 
@WheatWizard Meaning they'd have to loop, checking for the time to have advanced one second. The allowance just isn't relevant to them.
@WheatWizard Means every time the rest of the code (printing, calculation, etc.) accumulates to a whole second.
 
5:54 PM
If it means that it ought to say that.
 
@WheatWizard Can you edit it in?
 
@dzaima SOGL, 11 bytes: "⁹ē∑Ω-┌S°≡‘
 
I'm not going to do that because I think the implication of that statement is unclear. I'll let the author or someone confident in that assessment do that.
 
CMC: (Python) Define a function named zip that works exactly like the builtin zip function, but runs until the longest iterable stops.
For example:
>>> a = [1, 2, 3]
>>> b = [1, 2, 3, 4, 5]
>>> print(list(zip(a,b)))
[(1, 1), (2, 2), (3, 3), (4), (5)]
Or [(1, 1), (2, 2), (3, 3), (4, None), (5, None)] would be an acceptable output too
 
6:11 PM
@DJMcMayhem Why must it be named zip? :(
 
idk
It's not necessarily though
 
@DJMcMayhem Oh you don't care about code-golf?
 
Not really
It just seemed like an interesting moderately difficult task
You can golf it down if you like
Or score it by readibility
(which is subjective I know)
@WheatWizard Now do it in brain-flak :P
 
Anonymous
@DJMcMayhem from itertools import zip_longest as zip
 
6:13 PM
Uh, how do we represent a list in brain-flak?
 
@Mego :O
Oh my gosh that is exactly what I needed
Holy crap
 
itertools.izip_longest
 
Anonymous
(if you don't want the Nones)
 
That's why it's great to have a pythonista around
 
6:14 PM
Oh ninja'd
That's for Python 2 ^^^^
 
@WheatWizard zipWith(,) is just zip
 
Oh wow, I'm dumb
 
>>> a = [1, 2, 3]
>>> b = [1, 2, 3, 4, 5]
>>> from itertools import zip_longest as zip
>>> print(list(zip(a,b)))
[(1, 1), (2, 2), (3, 3), (None, 4), (None, 5)]
@DJMcMayhem ^ is that acceptable?
:P
 
I think Mego beat ya there
 
6:19 PM
i know
 
both of us :(
 
but i was asking because you said (4, None) was acceptable
but not the inverse ;)
you're not wrong though, it's a wonderful piece of awesome.
 
pedant...
 
Oh whoops
Yeah, swapping the outputs is probably not a good idea
 
that said
>>> print(list(zip(b,a)))
[(1, 1), (2, 2), (3, 3), (4, None), (5, None)]
just switching a and b works for what you're expecting
 
6:21 PM
Nope.
 
but for two lists being zipped you'd have to do some logic to determine what order to put them in
 
@ThomasWard No, you got it right. I just wrote that output by hand and screwed up
 
@Mr.Xcoder i'm beinng pedantic, I know. Sue me, I've been staring at scrolling diagnostic code all day :)
 
Anonymous
 
6:23 PM
I'll probably end up using the approach that keeps the Nones
 
Anonymous
(the second doesn't work if your source iterables contain Nones)
 
@DJMcMayhem Try it online! Another approach :)
 
@WheatWizard 67, not counting f=
 
Wait... Actually my approach has a tiny flaw
 
o.O
 
6:24 PM
@DJMcMayhem so, itertools' zip_longest then? :)
 
Yes, exactly
 
from itertools import zip_longest as lzip
:)
 
@WheatWizard >(n,n) instead of /=(n,n) works.
 
@DJMcMayhem Try it online! my approach revised
 
6:25 PM
Nice, didn't know you could compare maybes
 
But beware of bad practice, since it is my code :P
 
65 now thanks to help plus more pointfree
 
Uhm huh I learned something new today from the penguin, yield from
 
@DJMcMayhem it gets confusing though eventually
>>> from itertools import zip_longest as lzip
>>> a = [1,2,3]
>>> b = [1,2,3,4,5]
>>> c = [x for x in range(1,10,1)]
>>> print(list(lzip(a,b,c)))
[(1, 1, 1), (2, 2, 2), (3, 3, 3), (None, 4, 4), (None, 5, 5), (None, None, 6), (None, None, 7), (None, None, 8), (None, None, 9)]
 
CMC: Zip, but padding with the string "None" when needed: [10, 20, 30], [1, 2, 3, 4, 5] -> [10, 1, 20, 2, 30, 3, "None", 4, "None", 5] and [1, 2, 3, 4, 5], [10, 20, 30] -> [1, 10, 2, 20, 3, 30, 4, "None", 5]
 
Anonymous
6:27 PM
@Mr.Xcoder yield from x is a better way to do for y in x: yield y
 
@Mr.Xcoder Oh dang
 
also golfier
 
I learned two awesome things from the penguin today
 
Anonymous
It's also used for asyncio coroutines, which makes things headachey
 
@Mego I'm actually using that second approach in a couple places, I'll definitely revise that now
 
6:29 PM
@Mego I stack-overflowed it immediately, but thanks, that's good to know
 
Wait, no I'm not
Still good to know though
 
this is just me rambling, but I like how Python3 actually treats bytes as bytes instead of as strings like Py2 did. Py2 was a bit evil with bytes; Py3 bytes are actually bytes and work really well when parsing email data as emails heh
 
@Adám I see you have clarified the challenge. Thansk, I've retracted my vote
 
@WheatWizard You'er welcoem.
 
6:34 PM
CMC: WWzify and Adámify a sentence: reverse the last two letters of each word (no punctuation, a word is a sequence of letters separated using whitespace, at least 2 characters long) Youer welcoem -> Youre welcome
 
@WheatWizard Welcoem
 
@WheatWizard 37 bytes with lists instead of tuples: Try it online!
 
Ooh, nice
 
@Mr.Xcoder May we assume single space spacing?
 
@Mr.Xcoder Vim, 23 bytes: :s/\v(\a)(\a)>/\2\1/g<CR>
 
6:35 PM
Yes
 
@Laikoni what's the point of pure<$>
 
@DJMcMayhem Surprisingly fast :) Now do it in Jelly
 
Pass
I can do it in V though :P
 
Go ahead
 
Oh I see,
 
6:36 PM
@WheatWizard We need singleton lists for typing.
 
A direct translation is 11 bytes: Өᩨ᩾/²±
Buuuut there's a shorter approach
 
@DJMcMayhem what does the > at the end do?
 
@Cowsquack \> == word boundary
\v> == \>
@Cowsquack Think you can find the 5 byte V solution?
 
@Mr.Xcoder Dyalog APL (no regex), 30 bytes: 1↓∘∊' ',¨1⌽@(1 1↑⍨0-≢)¨' '∘≠⊆⊢
 
Great! I hate regex
@DJMcMayhem 5 bytes?!?!?! Neat built-ins
 
6:40 PM
No, no builtins at all!
It's just exactly what V was built to do
 
Ω_Ω
 
Actually, for that matter vim can do it in 11 bytes without regex
 
that was fun, it's been a while since I used V
 
Nice! FWIW, I did òeXpl instead, but it's pretty much the same thing
 
I think Vim beats me in Jelly
 
6:43 PM
I don't even know how I'd begin to try it in Jelly
 
Kudos to whomever beats me in Python 3.
For now, I have 63 bytes (Python 3 only)
Full program here
You're not allowed to take input / output as a list of words, both must be strings
Nvm 59
Make that 58
 
@Mr.Xcoder 53 :)
 
In Python 3?
 
Yes
 
51 in Python 2, but in Python 3...
 
6:56 PM
Should I reveal?
 
Oh wait
I'm not using a full program
That's why mine is shorter
 
@DJMcMayhem Doesn't matter
@DJMcMayhem no.
I use a function too for 56
@DJMcMayhem Are you using slicing?
 
Yes
 
Me too. Probably you're shortening [-2:][::-1] to the [x:y:z] syntax?
 
6:58 PM
58 for full program
Yeah
 
@Mr.Xcoder 50 :)
 
oh huh
 
Ping me when you want me to reveal
 
@DJMcMayhem lambda, def or full?
 
7:02 PM
Full
 
Oh ok
 
Yeah, I know. I wouldn't have expected full to be the shortest either
 
But how to you use [x:y:z] syntax here?
Um...
 
@Mr.Xcoder If you'd like, I think this would be a good challenge for main, and I could post my answer there
 
I'd make it main, but it's extremely biased towards V(i(m)) :P
 
7:06 PM
I see no problem with that :P
 
Naturally
How would I title it?
 
Flippign Lettesr Aroudn
 
Good one
 
I'm really proud of my Python answer actually. It kinda abuses some default behavior
And it's definitely a Python 3 only
 
I used *a,b,c=i
Did you do so too?
 
7:09 PM
Uhm
 
where i is the current word
 
I used a full program
 
IOW, did you use starred assignment?
 
I feel like I'm being really dense right now, but 1) IOW? 2) Starred assignment?
Do you mean *splat?
 
Yes.
 
7:11 PM
Yes
 
@DJMcMayhem 1) In other words 2) Splat
 
Oh of course
@Mr.Xcoder Are you planning on posting to main? I'd like to show off my answer there if possible
 
I will.
Soon
 
Cool
 
But I need a rigorous definition of words first.
 
7:13 PM
2 or more alphabetic characters separated by one space
 
Yeah, I'll use my definition above
 
Will there (may we assume/require) a leading and/or trailing space?
 
I'll think about that
 
@Mr.Xcoder More interesting challenge if words are indeed space separated, but punctuation should be ignored: You'reYou'er' and it's` → is't
 
Eh. I don't really find adding edge cases makes it more interesting
 
7:17 PM
That ruins DJ's solutions and mine. No, I don't like that
@DJMcMayhem Any test case suggestions?
 
idk
One word, case variations,
Do you guarantee each word is at least 2 characters?
 
Yes
 
@DJMcMayhem Again, more interesting if not.
→ oen wodr, caes variatiosn,
 
@Adám What should the output be for single words? No swaps at all?
 
WHY? Adding edge cases makes no sense IMO. Swap the last two letters of the character a :(
 
7:26 PM
@DJMcMayhem right.
 
So this is a test --> thsi si a tets
 
Should I tag it ?
 
0
A: Sandbox for Proposed Challenges

Wheat WizardTitle needed Your task is to print the text Greetings, Earth!, with every letter repeated in place as many times as the most frequent byte in your code. For example if your code was print p Since p appears twice you would need to print GGrreeeettiinnggss,, EEaarrtthh!! This is code-golf ...

 
@Mr.Xcoder A matter of taste, I guess. I like having sensible, but hard-to-code, edge cases. Otherwise it is too easy.
 
Yeah, matter of taste. Sorry for the bad tone
 
7:32 PM
will there ever be more than one whitespace in a row?
 
@Mr.Xcoder I think adding punctuation would be a major pain, but single letter words wouldn't be too bad
 
will whitespace always be spaces, or can it be anything?
 
(Of course, I'm biased because my solution handles single words lol)
 
@Cowsquack Only spaces.
Sorry!
 
7:33 PM
Sorry, lol
 
@DJMcMayhem that might force V to resort to regex
 
@DJMcMayhem I really don't want to add any kind of fluff :D
 
@Cowsquack True
 
6 mins ago, by Mr. Xcoder
Should I tag it ?
 
If things are whitespace delimited are they going to have to be put back with the same whitespace?
 
7:37 PM
@WheatWizard Example?
 
@Mr.Xcoder not really
 
e.g. hello\nworld -> helol\nwordl
 
@WheatWizard The input only contains letters and spaces (ASCII 32).
 
or hello\nworld -> helol wordl
Oh ok
 
What else? I have
 
@DJMcMayhem Umm, not really?
 
@WheatWizard coed golf, lol
@Mr.Xcoder Just a guess
 
Actually, um: Problems involving processing of natural languages in a human way. So I won't add it.
 
I'd say no
 
7:41 PM
Ok, should be posted in 2 minutes
 
ping me pls, I need to fwitw
 
ಠ_ಠ Will do
 
deleted?
 
Yeah. Brb reading and repsting
@WheatWizard @DJMcMayhem @Adám @Cowsquack Posted
 
I was fwitw'd
 
7:47 PM
First! :P
 
0
Q: Flippign Lettesr Aroudn

Mr. XcoderIn chat, we are often fast-typers and don't really look at the order of letters before posting a message. Since we are lazy, we need a program that automatically swaps the last two letters in our words, but since we don't want to respond too late, the code must be short. Your task, if you wish t...

 
@Mr.Xcoder I have enough rep, so I'd rather give others a chance. Thansk, though.
 
@Adám You're doing the right thing, just wanted to let you know :)
 
@WheatWizard fwitw?
 
Fastest West in the West
 
7:51 PM
I thought it was FGITW? Fastest Gun in the west
 
@WheatWizard ‽
 
It was a typo
 
Ok i thought it was "For what it's worth" for a sec
 
@Mr.Xcoder Fastest Golf in the west.
 
nah
 
7:52 PM
@Mr.Xcoder For what it's worth in the west
 
@WheatWizard You have been outgolfed!
 
No I haven't
that breaks one single letter words
I tried it
 
but "A word is a sequence of two or more letters in the English alphabet delimited by a single space"
 
@WheatWizard Read teh challenge again
 
"You may require your input to have one trailing and / or one leading space." this is too easy
not that any of the answers already use this
 
7:54 PM
brb removing that (cc @Adám)
 
@Mr.Xcoder In that case I golfed him back :)
 
Wow
wow o.o too many flags
 
Aww, that would have been nice for brain-flak
That's fine though, you can remove it
 
I did
Ok @DJMcMayhem that's a nice Python solution; +1
 
7:56 PM
But I might be able to outgolf you, trying it brb
 
I welcome the challenge
 
ಠ_ಠ much longer
 
@Mr.Xcoder Can we do IO as a list of Strings?
 
Hahaha I have an idea for Jelly
@ATaco As a list of characters, yes. As a list of words, definitely not.
 
Also, why in the example tHe oDd chALlEneg wiht swappde lettesR is the last word dropped?
 
8:00 PM
@ATaco Fixed
thx
 
@DJMcMayhem 4 bytes :D
 
@Cowsquack Oh dang. I had eXpl, but I didn't realize the e was sufficient to break the loop
Nicely done!
 
I originally had exP but that resulted in an infinite loop, wrongly thinking that e was not enough to cause a breaking error, I got ehxp for your challenge
 
Ugh, I only need 2 more answers for a gold badge
 
8:06 PM
-3
Q: Most creative way to display Hello, World!

CamdenIm suprised this didnt already exist. The Rules are simple: you must display hello, world! to stdout points are given for originality and interpreter creativity ( you are encaouraged to create your own interpreter ) please dont downvote boring answers This is not code-golf, long answers a...

 
Crossed out 5 looks like regular 5
 
@DJMcMayhem How do you people get so many gold badges, I don't even have an silvers other than code-golf
 
I'm like half way to my first gold.
 
@WheatWizard I only have one so far. It's cause I mostly answer string challenges
 
@WheatWizard Fixed The output may have one trailing space or one trailing newline.
 
8:10 PM
Someone, upvote ATaco!
 
10 bytes in Jelly for dylnan
 
Anonymous
@Zacharý Please don't do that
 
They're two questions away from the Taco hat
 
@EriktheOutgolfer You have my byte-to-byte 05ab1e solution (the 8-byter)
 
8:17 PM
Sadly, as much as I enjoy the free publicity, requesting votes is wrong, even for other people.
 
A taco for ATaco.
 
0
Q: Exponential-ish number sequence

BeefsterYour program must print out this exact sequence: 1 2 4 10 24 54 116 242 496 1006 2028 4074 8168 16358 32740 65506 131040 262110 NOPE! As usual, shortest program wins. Standard code golf rules apply.

 
damnit, I hit enter too soon on my domino post
 
8:40 PM
0
Q: Is this a valid game of Five Up (Dominoes)?

SparrA set of dominoes consists of tiles with two numbers on them such that every combination of integers from 0 to N are represented. The orientation of the tiles does not matter (they are usually printed with dots rather than digits), so [1-6] and [6-1] refer to the same time, of which there is only...

 
ok, it's "finished"
nice timing bot :)
 
8:55 PM
0
Q: Techniques for making code smaller

Sebastian BreitI came across dwitter which is a twitter for coding javascript ni 140 chars. I saw some cool things people do there for reducing the size of the code, for instance: c.width=α*2 uses a unicode char instead of a number. What other techniques do you know for reducing the size of your code to the ma...

 
:) I have 20202
 
NH.
So Dwitter.net is a valid language for new challenges, right?
 
00:00 - 21:0021:00 - 00:00

« first day (2524 days earlier)      last day (2304 days later) »