« first day (3091 days earlier)      last day (1735 days later) » 

1:57 AM
0
Q: Challenging you whether you master both c++ and java

Thuriya ThwinThis challenge is very simple.You have to write backjumping algoirthm for n-queens problem in java .If you don't know backjumping algorithm ,see wikipedia.If you don't know n-queens see I have provided the solution written in c++.This code works perfectly well. #include <iomanip.h> #include <...

 
2:17 AM
0
Q: What is Mr. Glass typing?

Jack JI assume that because (2019) Glass is a movie, and in my experience film makers don't feel they need too much reality to tell a story, that this code is gibberish. But I also wonder if maybe it might be my limited variety of language experience that causes this belief. My first curiosity is wha...

0
Q: Operation Unz̖̬̜̺̬a͇͖̯͔͉l̟̭g͕̝̼͇͓̪͍o̬̝͍̹̻

JoshuaI'm sure you're all familiar with Z̃͗̇̚͟Ḁ̬̹̈̊̂̏̚L̜̼͊ͣ̈́̿̚G̱̮ͩ̃͑̆ͤ̂̚Õ̷͇͉̺̜̲ͩ́ͪͬͦ͐ ̪̀ͤͨ͛̍̈͢ĝ̭͇̻̊ͮ̾͂e̬̤͔̩̋ͮ̊̈ͭ̓̃n͖͎̘̭̯̳͎͒͂̏̃̾ͯe͕̖̋ͧ͑ͪ̑r̛ͩa̴͕̥̺̺̫̾ͭ͂ͥ̄ͧ͆t͍̻̘̆o͓̥ͤͫ̃̈̂r̹̤͇̰̻̯̐ͮ̈́ͦ͂͞. If not, you can play with the classical generator a bit. This is operation unzalgo. The object is to undo the generate...

 
2:35 AM
I may or may not have made a mistake. I searched for similar posts before posting my operation unzalgo and found none. Only after a few edits did 'he cometh not' show up, which is a very simple zalgo cleaner problem that I considered too boring to post. In early derivation days ago I already had cöop passing through undisturbed.
Yes, I spent a few days devising this problem.
 
 
2 hours later…
4:36 AM
Is the "don't have an account" banner supposed to say "Code Golf Stack Exchange is a question and answer site for programming puzzle enthusiasts and code golfers." in that order, given the new site name?
 
@Οurous I think that's intentional. The tour page has certainly been looked at, and has the same phrasing.
 
That's not evidence. The most likely explanation is $site_audience in the help template.
 
 
2 hours later…
6:19 AM
damn, i can't see removed posts anymore
 
 
5 hours later…
11:40 AM
0
A: Sandbox for Proposed Challenges

A__Design a language as "sweet" as possible In this challenge, you are required to create a language that has as many syntactic sugar as possible. Yes, it does not have to be a programming language. The documentation of the language without all the syntactic sugar will be counted in chars, and the ...

 
 
2 hours later…
1:30 PM
@SriotchilismO'Zaic Can Barin-Flak (BrainHack) be added to the polyglot (since the comments work differently to the other implementation?
 
1:43 PM
CMC: Given three values, a, b, and x, with a<b, answer the index of the true comparison: x<a, x=a, a<x<b, x=b, x>b (0- or 1-indexed)
 
@Adám Python 2: lambda a,b,x:2-cmp(a,x)-cmp(b,x)
 
@Adám So b must be at least 2 greater than a?
 
Ruby: ->a,b,x{(x<=>a)+(x<=>b)+2}
 
If they're all integers at least
 
@DJMcMayhem There are cases for x=a and b=x
 
1:48 PM
@DJMcMayhem No, only a<b.
 
"Planck length"? I prefer "ULP".
 
@JohnDvorak That's only for floats.
I'll be offline for a couple of hours, so for future readers: I have 9 byte APL solution (found after posting the challenge, btw)
 
2:12 PM
@Adám But if a+1==b, then a<x<b and x=b are both true
Err wait, that's not true
I mean a<x<b can't be true
 
2:38 PM
@H.PWiz Maybe. It is really hard since all braces need to be balanced across the program to avoid syntax errors.
I don't think there is anything that strictly forbids it though
 
2:59 PM
0
A: Sandbox for Proposed Challenges

bigyihsuanWrite an X-SAMPA Interpreter Tags: code-golfunicodestringinterpreter Write an X-SAMPA interpreter that, when given an X-SAMPA string, outputs an IPA string. Some Background SAMPA is a system for encoding sounds from various languages into a computer-readable ASCII format. X-SAMPA is a descend...

 
3:15 PM
I'm beginning to regret asking that second Jimmy question
 
In the future, everything is Jimmy
 
Did we already notice that the medals on our profiles are actual medals now and not just colored circles
I feel like I knew this already but I don't remember when it happened
 
Oh yeah neat.
I hadn't noticed
 
Done! :D Wonders of having so many different badges already. :D — Catija ♦ 17 hours ago
yep, that's because it's new
 
4:13 PM
> Famously used for the shirt of Mark Woffenden, a prolific goalscorer known for precision and power when he was 17 himself now hes 58 he disgraces the 17 numeric and will continue to do so until his failing achillies tendons retires him for good. -- Wikipedia article for 17
 
CMC: What's the rarest badge you have?
 
On PPCG code golf
 
Mine is research assistant
 
4:17 PM
@SriotchilismO'Zaic Only two awarded, nice
Mine is steward
 
I'm hoping to get steward this year.
 
Outspoken <_<
 
I don't think I am ever going to get Marshal, 500 is a lot of flags.
 
I'm confident that I will never ever earn Marshal :P
 
most of mine are from flagging NLN comments :D
 
4:19 PM
Too busy handling flags to bother raising them (also I think it's impossible for me to get)
 
I think Socratic is my rarest
 
hm, maybe flag-deleting something counts as a flag
 
But a Sheriff badge isn't bad
@EriktheOutgolfer I vaguely remember reading somewhere that even if I flag something it doesn't count towards marshal
 
Although silver KC is pretty rare, too
 
yeah me too, let me check the badges post over MSE again...
oh lol tag badges are another story
 
4:22 PM
19
A: Aren't moderators eligible for the Deputy and Marshal badges too, or has it changed?

Adam LearThese flags do count towards the badges when appropriately dismissed as helpful, but moderators aren't eligible to receive either Deputy or Marshal badges according to Geoff Dalgas: The Deputy and Marshal badges are only granted to registered users - not moderators.

So I'd have to step down to get a marshal XD
 
> registered users - not moderators
this... does look weird
 
Fun badge related fact: I don't have steward but I do have more reviews total that both the people who do.
 
@EriktheOutgolfer Oh true, Dennis and Neil have the two rarest badges
 
@DJMcMayhem 1) Step down, 2) ???, 3) Profit
 
Martin has a 1-awarded badge too
So only 3 people can claim to be the only person with a certain badge
 
4:25 PM
CMC: What is the badge you have the most of?
 
@SriotchilismO'Zaic 98 Nice Questions
 
@SriotchilismO'Zaic Nice question
 
98 Nice Question here, too
 
Nice Answer
 
I doubt that anyone would say anything other than nice question or nice answer
 
4:26 PM
I bet you stasoid has necromancer
 
@AdmBorkBork crazy how nature do dat
 
who will get to 100 first er... what a coincidence...
 
Daaaaaamn
 
Jesus Wept
 
4:28 PM
Mine is nice question btw, which should not be a surprise.
 
Oh, can we count Meta Code Golf for rare badges? Because then I have Publicist
 
btw, stasoid has got the 86 badges from two challenges
@AdmBorkBork nope :D
 
@EriktheOutgolfer I've only ever seen them answer the "Add a language to a polyglot" challenge
 
Interesting... There are no sheriff badges on meta.
 
wait... HOW
I mean, the main and meta diamonds are separate
 
4:30 PM
My rarest meta is Tag editor (29)
 
I'm aiming to get discussion gold so that I can dupe hammer the sandbox
6
 
my rarest meta badge is... Curious
 
@DJMcMayhem Strunk & White, I guess. I'm nowhere near Copy Editor though.
 
5:04 PM
@DJMcMayhem how do I find how well cooked my badges are?
 
Cut into the middle
 
but I don't wanna cut snakes
 
> I kill 'em snakes and stick 'em on my uniform
 
please no
 
@flawr A snake got into our office the other day
He was just chillin on a bucket
 
5:19 PM
Must be hiding from the Walrus
 
@DJMcMayhem Probably got there for a job interview?
 
I think that's a reasonable guess
 
@DJMcMayhem are you using windows in your office?
 
Do you mean windows or windows? :P
 
5:34 PM
the os
 
pretty sure he meant windows, because during a sweltering summer windows are crucial...
 
just asking because the snake would have difficulties pressing crtl+alt+del
 
Ah, got it.
At first I thought you wondering if the snake got in through the windows, but now I realize that doesn't make any sense at all
@flawr Yes
 
Well it did get up on top of the bucket somehow
 
5:38 PM
@EriktheOutgolfer Can+Snakes+Climb+the+Corporate+ bucket ladder
 
6:07 PM
My aunt and uncle live across the road from a national park/ecological reserve here in Brazil. They once found a ~2m long alligator inside their elevator on the third floor.
 
How else would you expect an alligator to get to the third floor? Taking the stairs?
 
Did we have a Portguese chat room for our site?
 
Clearly it was an air drop sent to fight the pigeons
 
Just had 2 curls downloading the same data... They finished with different file sizes and neither one had the complete download. Turns out I was out of disk space
sigh
 
@EriktheOutgolfer Lots of issues appear fixed.
 
6:13 PM
@Poke RIP
 
@Poke always download enough disk space first
 
6:28 PM
@SriotchilismO'Zaic I don't think so, although there is a Portuguese Language SE
@flawr the most bamboozling thing was how in the heck did a ~2m long alligator go past a fence and two doors in order to get into an elevator. Park officials who went to retrieve it said it happens all the time with nearby buildings.
 
CMC: Shortest program that does terminate but times out on TIO (60s). No time-related built-ins allowed (getting the current time, sleeping, etc.)
@J.Sallé A friend of mine had a mountain lion break in to his apartment and eat his roommate's cat.
 
@DJMcMayhem So we have to rely on keeping the processor busy?
 
Yes (although a busy loop is not allowed)
 
@DJMcMayhem I'm not sure I understand your parenthesis, but VTD as malicious.
 
How is that malicious?
Unless you're worried that we'll DDOS TIO, in which case I could change it to shortest code that takes over a minute to execute
 
6:38 PM
Haskell: main=print$9^9^9
 
@DJMcMayhem 21 bytes 1e6..9e6|?{!($_%1e6)}. I think this is my only answer that times out on TIO.
 
@JohnDvorak That's probably going to be the winning approach for most languages.
 
@DJMcMayhem damn
 
@flawr the classic blunder
 
6:43 PM
@DJMcMayhem Why didn't they just take the mountain lion as a replacement pet?
 
That would be my suggestion as well
It's not like they're deadly predators or anything
 
@J.Sallé So are cats
 
@flawr except cats are too lazy to kill humans
 
There's only one animal species that will bite you out of boredom. Guess which one?
 
@JohnDvorak Mathematica seems too fast to do this
 
6:47 PM
I tried Ruby, but it insists on switching to floats
 
@DJMcMayhem APL (Dyalog Unicode), 7 bytes ÷⍣1e9⊢7 (10⁹ reciprocals of seven)
 
@JohnDvorak now I really want a mountain lion as a pet
 
@flawr For some reason, I read that in Lrrr's voice
 
7**7**7 is fast even in Ruby, and 8**8**8 just flat out gives up
 
@DJMcMayhem sorry, I don't know futurama
@JohnDvorak only 19.99?
that sounds like a good deal
 
6:51 PM
@JohnDvorak What do those expressions mean?
 
also keeps my neighbours cats out of the yard I hope
 
That's cheaper than a monitor stand
 
@Adám repeated power
 
@Adám the CMC
 
@Adám Exponents, because ^ is XOR I assume (like python)
 
6:52 PM
Three answers in quick succession, none of them answered what I intended to ask.
 
keep ^ as symbol for power and make ** the symbol for xor
 
@JohnDvorak Can you translate that to traditional mathematical notation for us non-Rubyists?
 
It's exponentiation
 
@Adám 7^7^7. ** is the symbol for exponentiation
 
@DJMcMayhem 7^7^7 is not traditional mathematical notation (∧ is logical AND, if anything).
 
6:55 PM
now it just remains to know whether it is (7^7)^7 or 7^(7^7)
 
@flawr Exactly. Hence my request.
 
@DJMcMayhem Oh. I misread this as "shortest answer (you've posted)" instead of come up with something new. In that case, 1..1e6|%{$_} should work for 12 bytes.
 
@Adám it is/was quite frequently used to write out expressions on computers when there is no LaTeX available
 
@Adám i'd call it traditional ascii mathematical notation. you can't really represent it in ascii otherwise (and ** for power is pretty standard too)
 
@flawr The second (I'm 96.4% sure)
 
6:57 PM
I understood that ** and ^ were exponentiation, but none of them convey the meaning of superscripting in TMN. Is it indeed ₇7⁷ or (₇⁷)⁷?
 
from a math point of view (and Haskell agrees) a^b^c is a^(b^c)
 
Not even the superscript notation avoids that
 
Well if we're being pedantic, ₇7⁷ isn't standard mathematical notation either, so it can't even be answered
 
@DJMcMayhem Font size aside, it is, and it is 7⁴⁹.
 
left-associative exponentiation is clearly useless because you can multiply instead
 
6:58 PM
 
@JohnDvorak yep, but it is still used in many other languages
 
@DJMcMayhem Saw it as three angles like > pointing up-and-right and now can't unsee it.
 
Which ones? PHP doesn't count.
 
for example octave/Matlab
 
@JohnDvorak Algol, Basic, Groovy…
 
7:05 PM
... matlab?
 
what's wrong with matlab?
 
It's not MATL?
 
@flawr I'd expect better from a language for, well, math..
 
This is what's wrong with matlab. And of course the cost, too.
 
@dzaima I think it is at least consistent with all the left-to-right evaluation
And if you actually need nested powers in a numerical context something has gone horribly wrong:)
 
7:22 PM
Woah, the chat mobile theme just updated
 
@DJMcMayhem Heh, I just asked Catja for that a few mins ago.
code
Doesn't the new mobile chat theme look very outdated?
 
@Adám at least it's not beta blue... ;P
 
@JohnDvorak Io, Kotlin, Rexx, Rust, Simula, …
 
...Kotlin? I thought they'd know better
 
Another fun one is 4/2/2
 
7:34 PM
I'd say that is pretty much always evaluated left to right, isn't it?
 
@flawr Except in TMN, where it really should be right-to-left.
 
what is TMN?
 
@flawr Traditional Mathematical Notation.
 
@Adám Even then I'd say it is (4/2)/2, but really it is just a bad idea to use an inline / in such a case
 
@flawr Precedence is evil.
 
7:37 PM
oh matlab has a fun one: what is 2\4/2 ? :)
 
Ah, a\b is b/a, right?
 
right, except when the operands are not commutative
 
@flawr It evaluates to the sound of a programmer quietly sobbing
2
 
Well actually the one I posted was kinda obvious
try 2/4\3 instead:)
 
What is 4 ÷ 2 × a ?
 
7:41 PM
(4/2)*a
 
@flawr What is 4 ÷ 2 a ?
 
@Adám 4 / (2a) :)
 
@flawr Precedence is evil.
 
@Adám Error: ambiguous expression
 
What is sin a × b ?
 
7:43 PM
It's a sin.
 
@dzaima Interestingly, a few (but very few) language have that.
 
@Adám once i wanted to get an answer to something like that from my math teacher. didn't get a conclusive one :D
 
What I do like in haskell is that you can define the precedence as well as the associativity of binary operators.
 
@dzaima Right, it is because it (officially?) depends on the goodwill of the reader.
 
Caused by the incompetence of the writer
In math one should really try to avoid expressions like these, even if not everyone is doing so.
 
7:45 PM
sin a cos a is "obviously" (sin a)(cos a), but sin 2 a is "obviously sin(2 a) so there is no blanket precedence of sin vs (implied) ×.
 
@flawr even more evil, sin 2a × a
 
@dzaima lol
 
@Adám the latter depends on how much space there is between the consecutive symbols :D
 
i wonder if there'd a big difference from interpreting sin 2a × a and sin 2a×a
 
Bob eying quilts, quietly sobbing
 
7:47 PM
but really the unclear conventions caused us to use monstrosities like ⫋
 
@flawr Well, I does that.
 
@Adám funnily enough, I tried to see what google thought was more 'obvious'. sin 2 pi is sin(2 * pi) but sin pi 2 just doesn't get evaluated by the calculator haha
 
@dzaima Wow!
 
That's because 2 is actually a monadic function that multiplies its argument by two
while pi is a mathematical constant
 
7:49 PM
‽‽‽ \○/
 
@JohnDvorak I can't tell if that's a joke or not
 
@JohnDvorak and in this context I use unary because monadic has other meanings in programming and math:)
 
ah, yes, unary.
 
@dzaima But sin 2a × b and sin 2a×b are both sin(2a)b!!!
 
@DJMcMayhem bah, I would read that as sin 2 × π
not as sin(2 × π)
unfortunately it's not really my choice though
 
7:52 PM
There needs to be a jimmy tag. — MilkyWay90 24 hours ago
What do y'all think?
(Got to run now, meetings.)
Nice series of questions, BTW.
 
I would lean towards no
 
definitely no, trends come and go
 
@Hosch250 just because some guy decided to repeatedly use the name "jimmy" in his challenges?
I think we've even banned the useless backstories a while back...
 
@Hosch250 Nope. It adds nothing to the site.
 
7:55 PM
Useless backstories are an integral part of any challenge. Please don't get rid of them!
 
@flawr they've not been completely banned, they just shouldn't be long enough to distract from the challenge
more like discouraged
 
If sin²x is (sin x)² and sin⁻¹x is arcsin x, what is sin⁻²x? (arcsin x)²?
 
totally unrelated, did you guys know you could eat (some of them) physalis fruits?
they are delicious, I just recently found out that there are actually edible varieties
 
@flawr sure, they are common as desert decor.
 
@Adám sin ^ (-2) x is a debated topic
 
8:01 PM
sin sin2x2 vs sin sinx2 vs sin sin x2. ok that's enough precedence for me
 
the convention that sin ^ a x means (sin(x)) ^ a and not (sin ^ a)(x) is stupid IMHO
 
@Adám sin⁻²x = sin⁻⁻¹*² x = (sin⁻¹ x)^2 = (arcsin x)^2
@EriktheOutgolfer it is usually very clear which one it is from the context
 
@flawr W⍺ says (sin x)⁻²
 
yeah, "context" shouldn't do the justice in maths, ever
 
and if you want to be sure that people understand that you mean repeated composition, then prepend a composition circle symbol to the exponent
It is not a very standard thing to do but people will always understand.
 
8:03 PM
I'm pretty sure that the composition symbol doesn't take a number as its right operand...
 
@EriktheOutgolfer yes but people understand:)
In math so many notations and notions do depend on the context.
Otherwise we would have long run out of symbols
 
Whoa, W⍺ splits sin^-1.2 x between 1 and . !!!
@flawr Nah, see APL.
 
@flawr Really common around here. Sold by the basket, as desert deco and even as ice cream
 
@Adám How many symbols does APL use? I bet math uses even more:)
 
@Adám well APL does have like, a lot of symbols
 
8:06 PM
@mınxomaτ really? Now I really need to find them...
 
@dzaima But we're not even close to running out of symbols (only running out of keyboard space).
 
@Adám haha:) is there no handwritten version yet?
 
@flawr It was originally hand written. Iverson was a mathematician. We have his blackboard in our board room at my office.
 
how cool is that!
 
8:11 PM
@Adám so around 125 additional symbols to lower-&upper-case alphabets and digits
while many languages probably use around 10-20 symbols
 
@flawr The Dyalog interpreter self-reports that it recognises 85 non-alphanumerics/whitespace. (I just asked it.)
 
these are probably the symbols supported by many languages +@"#*%&/|()=?''^`$][!-_.:,;\<>{} which are about 33, actually more than I expected
 
@flawr two 's?
 
@Adám is that just functions & operators or also brackets, quote char, more?
 
@dzaima Including brackets/parens/braces, but excluding quote char.
 
8:17 PM
@Adám one should be a thing that goes from the bottom left to the top right, but the typeface here probably doesn't support it
´´´´`````'''
or I just mistyped it:)
 
@flawr But ´ isn't in ASCII
 
what about the number 27 (dec)?
 
ah no, that seems to be the ' depending on the typeface....
 
@flawr Escape? It isn't usually used in code, methinks.
 
8:20 PM
@Adám didn't perl 6 also have like hundreds of unicode chars allowed as alternatives for numbers?
 
huh the table I just used was actually wrong
 
@flawr those are actually eaten a lot in northern Brazil. It's known as juá-in-a-coat because it looks like a juá fruit... wearing a coat, I guess?
 
googling juá fruit
@J.Sallé don't know them at all :/
 
They're really common in northeastern Brazil because it grows in semiarid conditions. Tastes great but makes a mess
 
A mess in what way?
 
8:34 PM
They're very sticky and it's very hard to clean your hands properly afterwards
So eevrything you touch gets all sticky too
 
 
1 hour later…
9:52 PM
I have a question related to the Turing Completeness of a dialect of BF
Imagine a version of BF where every operation was applied to a variable (except brackets)
Like instead of +>+, it would be increment the first element in the tape. Increment the second element in the tape
 
10:11 PM
@MilkyWay90 so you're asking, if BF replaces > and < with an infinite number of commands "set the pointer to position N" where n is an integer, is it still Turing complete?
 
10:27 PM
@lirtosiast yeah that'd work too
 
10:44 PM
@MilkyWay90 That wouldn't allow for having infinite memory ≡ not turing complete
 
11:41 PM
@dzaima Oh, okay
 
(unless the numbers in the cells aren't capped in size, then it depends on what the operations on them are)
 
@dzaima I'm talking about a version of BF where cells don't wrap, they can be (theoretically) as large as they want
what operations would be needed?
 
no idea. make an interpreter and see if you can make a BF interpreter :p
 
hmm
 

« first day (3091 days earlier)      last day (1735 days later) »