4:00 PM
-1

Muffin or Chihuahua? Inspired by this tweet You must determine if the supplied image is a Chihuahua or a muffin! The images will be those in the status image above and shown below. The images will be cropped out to just be one. Rules Usual rules. Input One of the images below cropped out ...

@Riker Well, a PowerShell builtin for a Windows vulnerability kinda makes sense. The empty Jelly program works on all my machines though.

true

Statistics question: are there any other "linear" properties of probability distributions? For example: the expected value of a sum of independent random variables is the sum of their expected values. Also, the variance of the sum is the sum of their variances.

4:16 PM
1

Objective Create a function to reverse string concatenation Input Two strings, where one should be subtracted for the other. You can assume that the string to be subtracted will never be larger than the other one. Output The result from the subtraction Subtraction You should remove on...

4

TL;DR What rules and guidelines should duels and duelers be held to? This idea sprouted originally as a potential solution to this problem. It was well received so the next step is to create formal rules and to address foreseeable complications. What is Dueling? A duel is an arranged eng...

slow much?

Part of the problem is probably that I had to look up chord, but even now that I did, I'm not sure how to translate chords into something a computer can understand, how C,Am,F,G is a transposition of F,Dm,A#,C, what exactly you mean by in any format, and which methods of "playing" are acceptable. — Dennis ♦ 26 mins ago
Agh, the music nerd in me wants to argue about how it should be Bb instead, but I realize that that's nitpicking and totally unrelated

I don't know anything much about music

@DJMcMayhem yes, I cringed at that also

4:27 PM
F is the IV chord of the C Major scale, and Bb is the IV of the F Major scale. The reason it wouldn't be A# is because A is already in the F Major scale but as a natural

also s/Bb/B♭/ but ye

Meh

lol

I took me while to read F,Dm,A#,C, because its so hard to hear that in my head

A# is the IV of the E# scale which nobody uses because it has four double sharps and 3 sharps which is a ridiculous key to use

4:28 PM
or the I of the A# scale :P

Now I know why to prefer Bb over A#. TIL

@NathanMerrill yea, I was confused about a#. took me a bit to realize that was b flat

all I remember from those music classes I had is that C# is pronounced as "C sharp"

> music classes

realistically speaking, the most likely time when you'll see A# is in the F# key when they want major III

4:29 PM
it was in school
and compulsory

@NathanMerrill Yeah, but then the chord progression would be A#, F double sharp minor, E#, D#

like, some sort of I III iv V pattern?

it's been edited into code-golf instead of a popcon
@DJMcMayhem this bold hurts my eyes :p
try backticks?

Also, if the whole point of the challenge was that the chord progression is over used so it applies to a whole bunch of different songs, he should have used I, V, vii, VI instead

> F double sharp minor

4:32 PM
"F double sharp minor" Oh god...

I totally think that I vi VI V is far more common than I V vi VI

ninja'ed

@Riker It's painful but true

yes but why would you ever use it

You wouldn't. That's why you'd never ever ever ever ever use A# when you could just use Bb

4:33 PM
As someone who loves music but has never learned the music theory terminology... what's the difference between VI and vi?

(And yes, I know I said b instead of flat)

@ETHproductions FAC vs ACE
(In the key of C)

No?
Those are both 6
FAC is 4

oh!
ACE vs AC#E

I think he's saying uppercase/lowercase

4:34 PM
Yes

I read the VI as IV

I think uppercase is major and lowercase is minor, but I'm not positive

@ETHproductions lowercase often means minor

idr about that context, it's been a couple months since I last played

4:34 PM
@NathanMerrill Is that standard/common?
Stupid double post

AC#E is a very common chord

No, I meant the case distinction for major/minor

Oh, so VI versus vi is ACE versus... um... ACD#?
(or ACEb, not sure which is correct)

No, that's an A diminished
A Major is AC#E

4:35 PM
typos XP

Sorry, I was still stuck in C major/minor

Ahhh, yes
A C minor is C Eb G

so, chords are always thirds stacked on top of each other
so, that is why you always skip a letter when describing a chord

Yep.

so, ACD# isn't how you write it, its ACEb

4:37 PM
And scales always increase one letter at a time

@NathanMerrill Ah, that makes more sense

Since it seems we have enough music theory nerds in here right now, my biggest pet peeve with guitar players is that every single time they play in F, they call the IV chord A#. Every time without fail.
It really irks me. Like nails on a chalkboard
Piano players never have that problem. :P

oh really? I don't really know many guitarists, so that's humorous

@KritixiLithos The programming language is actually called C♯, not C#.

I can see how that's true, if they just learn standard chords and pair them together

4:39 PM
@DJMcMayhem What's wrong with A#?

@NathanMerrill That's one reason, but the other big reason is that every major scale is exactly the same fingering, so you don't need to learn the scale note names

@Adám huh, I thought it was pronounced C-octothorpe

@programmer5000 Scroll up. :P

@programmer5000 so
many
things

We've been ranting about A# for 10 minutes lol

4:39 PM
^
just call it b flat
that's what it is

.oO(Not always though)

The only time I want to see your A# chord is if you're in the key of F#

@NathanMerrill solution: don't go in the key of F#

@Adám I meant C-sharp, but seems like I got confused between the hash and the sharp

F# is so much fun though :)

4:40 PM
@NathanMerrill neither the language or the key are imho

@Riker Nothing wrong with F#. Since F#/Gb have the same number of sharps and flats, neither one is preferable

@DJMcMayhem I just don't like it
either f# or g flat

Could this be reopened?
-2

Your challenge is to play these notes (speakers or to a sound file): C A F G You may find this useful. Playing these frequencies would be allowed: 261.63 220.00 174.61 196.00 And so would this: 1046.50 880.00 698.46 783.99

just doesn't sound good imho

I find that keys with a bunch of sharps/flats are much more enjoyable than ones with 3 sharps/flats

4:41 PM
@Riker What instrument do you play? piano?

but whatever, I'm out now (gonna go for a quick run)

Why doesn't Visual Studio include D♭?

@DJMcMayhem Would you prefer it be called Bb?

see y'all later
@Mayube he's already said that, yes

@Mayube Depending on context, yes

4:41 PM
@ETHproductions yes, used to play a bit of ukelele though

As a music producer and pianist myself, I don't think I ever refer to them by their flat names, I always favor sharp

what? So you play in the key of A#, not Bb?

Anonymous
I look away from chat for 10 minutes and now I'm having flashbacks to high school

Yes, and I use the A# chord.

I have always thought of it as A# as well

4:43 PM
Or is it the Bb chord?

Anonymous
For a short time, I actually wanted to get a degree in music. Then I decided that I wanted to make money.

@JanDvorak I think the consensus here is that it's Bb unless you're playing in F#

@JanDvorak Only problem with that is that the notes of the A# chord is A#, C double sharp, E#

Musicians do make real money

Like 0.0002% of them. :P

4:44 PM
well, I'm a musician. And I make money

Anonymous
@JanDvorak A small percentage of people who go to school for music make enough money to support themselves. An even smaller percentage of people make enough money to support themselves and a family.

just not from music :)

Correction: pop singers make real money

Anonymous
The rest of the musicians make Monopoly money

4:45 PM
@DJMcMayhem very accurate

5:02 PM
what in the world

1 message moved to Trash

user165474
Anyone interested in running through the Snowball KoTH controller runs? I don't have time right now but I can do it like this weekend or sometime tonight if I'm lucky.

@HyperNeutrino how much effort would it to be get the languages set up?

5:18 PM
@HyperNeutrino when you post a KoTH, you really need to commit to the time to run it

user165474
@NathanMerrill I've confirmed that I can make time tonight, but new submissions after tonight might not be tested until Thursday at the earliest.

user165474
How often typically should I update it

people get impatient with their submissions, but I usually try to do 1 run a day

Daily if possible for the first week

user165474
5:20 PM
@PhiNotPi Not too much, as long as I can run the program from the command line

user165474
@NathanMerrill alright. I'll see if I can get some time tomorrow morning before class

In related news, I've also been seriously committing to this KoTH server. I think I have the SQL tables designed, and now I just need to figure out how to make a Java webserver

@NathanMerrill Is this going to be, like my KOTH server but done right?

same concept, yeah
what mistakes did you make?

Well, it was never really polished at all. But basically the way it worked was that there are two different "main" programs for each challenge: one that is the controller which can run in the background and updates the database, and one which is run whenever you load the page that accesses the data from the database to generate the leaderboard or other page content (like graphics).

5:27 PM
So, I'm going to require people to use my framework. This gives me a couple of bonuses:
1. Each game produces a scoreboard so for a tournament, I can list out all of the games

One of the things I wanted to do with my server was a "live"-bitcoin-trading challenge: every couple minutes your bot will get a turn to "buy" or "sell" bitcoins (based on the actual current value of bitcoins), and your score at any point is what your return on investment would have been if you had actually been trading them.

2. This allows me to also have a table for bots, and the games they participated in, for useful debugging

And so the controller would actually be running continuously, with scoreboard updates every 15 minutes or so.

3. I've learned way more about JavaFX (with my current job), so I'm really considered allowing people to have both a local webview to watch a game, as well as a StackSnippet to watch a game from the server
5. Score aggregators (like MAM, or even simple ones), can show a breakdown on how their scores were updated

user165474
Mostly the reason I can't commit as much time as I'd really like to is because I'm in high school so most of my day is wasted doing nothing spent learning things or doing nothing homework.

5:32 PM
@NathanMerrill Do you think you will be able to support some kind of real-time or continuously-running competition on your server?

5:42 PM
Potentially, but it'd require a large rework
I still have a pretty strong hierarchy of "Tournament of Games"
and real-time breaks that
because a game never actually finishes
I'd need to come up with some sort of class that runs a "game of rounds", and each round it updates the scoreboard?
I mean, tournaments can last forever right now
so I could repurpose them to be the actual game
but that might end up being super hacky

@Lithium "A Stack Overflow themed Jenga game" is a pretty good metaphor for how most software development works 😜 — Benjamin Hodgson ♦ 1 hour ago
2
This comment is beautiful, 10/10

One more vote to reopen:
-2

Your challenge is to play these notes (speakers or to a sound file): C A F G You may find this useful. Playing these frequencies would be allowed: 261.63 220.00 174.61 196.00 And so would this: 1046.50 880.00 698.46 783.99

Oh well, I'll do it.

Anonymous
I'm not going to vote to reopen because the chord information should be in the challenge body, not a link

@programmer5000 what's a sound file?

5:53 PM
@NathanMerrill .ogg, .mp3, etc.

I need a definitive list
because ABC notation seems rather appealing

Anonymous
These problems could've been worked out in the Sandbox

also, do you allow any C note?
^^

@NathanMerrill and yes, any C note.

In the post!!
then please say that in the post, and how to calculate their frequencies

5:54 PM
Also, how long should the sound file be? What note lengths?

Anonymous
The challenge should contain all of the information needed to craft a solution, assuming that the only thing a user knows is how to write code in a programming language.

Whats a good number challenge to do in a new language?

primes + fibonacci?

project Euler

OH yeah fibonacci, thanks

5:56 PM
@NathanMerrill is that better?

@Mego Is it really required to explain what a note is?

I hope not.

It's crucial to prevent abuse

Anonymous
@programmer5000 No, because it's still a link, not an unambiguous description. Put a little bit of effort into your challenge writing, please.

not because people can't look that stuff up

Anonymous
5:58 PM
@JanDvorak You'd be surprised how many people don't have any experience with music.

but because if you don't define it, then anything goes

Anonymous
If you say "A", a lot of people don't have any idea what that means.

He did list the note frequencies

right, but he listed two of them, and also said that any "A" works
if you're going to allow multiple frequencies, tell me exactly which ones

true

6:00 PM
because even "A" is broad, which is why (in the world of tuning) we say A440

You are not currently allowed to play any "A", just 220.00.

Eep, sorry for the earlier message, though I hope it didn't disturb anyone.

Anonymous
@NathanMerrill And then that's still not enough, because of equal temperament vs just temperament vs others

@Mego that's not a property of a single note

Is 220.00 HZ fine?

Anonymous
6:01 PM
@JanDvorak Sure, but there are multiple notes

Anonymous
This music challenge of mine spent a lot of time in the Sandbox, going through revisions to make it clear.

@programmer5000 it's looking better. I'd indicate that the notes have a minimum length of X seconds

It has that.
Or are you suggesting > 100ms?

Now there are four specific frequencies to play, so there should be no need for too much theory. Specifying an allowed error for the frequencies would be nice, though.

oh I missed that

Anonymous
6:03 PM
@programmer5000 Loophole: Each note lasts infinity seconds

It's 0.1s for each note, but where did the 0.25s between notes go?

Not needed.

What is unclear?programmer5000 13 mins ago
@programmer5000 Instead of screaming at us in comments, you might want to consider explaining the task at hand as well as you can. What might very well sounds clear in your head, since you already know what you want us to do, might not be clear at all to readers.
2

@Mego I'm surprised nobody found a codec for ABC notation
because seriously, once its found, that is super abusable in your challenge

user165474
Note that 220Hz with a square wave does not sound like an A (IIRC)

6:08 PM
Why not?

I think there are defaults for allowed audio outputs?

Anonymous
@NathanMerrill I'm surprised, too. I didn't even try, though :P

Funny how Java beats python by a huge margin in this challenge.
2

Anonymous
@HyperNeutrino It mostly sounds like ruptured eardrums
2

Anonymous
Actually it sounds like chiptunes :P

user165474
6:11 PM
lol square waves do sound bad

That's why the era of 1-bit audio ended as soon as it could

user165474
Hm. Actually it does sound like an A, just an octave higher and fatal to the eardrums.

user165474
@JanDvorak that existed?

Anonymous
@HyperNeutrino Telegrams :P

user165474
oh :P

6:15 PM
a square wave is just a sine wave with massive amounts of higher harmonics

user165474
lol That is true.

anyways, g2g pub

user165474
bye! o/

Is anything still unclear in my challenge? If so, please tell me, otherwise please vote to reopen it.

Anonymous
> If you output to a file, please use a .ogg or .mp3.

Anonymous
6:17 PM
What if output is done on STDOUT?

Normally just raw bytes that can be fed to aplay are allowed

`./prog > file && aplay file`
srsly ninja'd?

just do `./prog | aplay`

user165474
`./prog | aplay`? or can i not bash?

Anonymous
@JanDvorak Other way 'round

6:20 PM
why the stars

Anonymous
Ok these ninjas really need to get out of TNB

user165474
:(

jumps onto the roof, disappears into the darkness

Anonymous
Please don't star things that aren't important or interesting. Starring things just to star them doesn't benefit anyone.

user165474
tries to jump onto the roof, trips, and falls out of sight

user165474
6:21 PM
Welp I gtg now. Bye! o/

bye

@totallyhuman did you just join to say bye? O_o

i came, i saw :PJY

veni, vidi, dunno
7

veni,vanna,cry

6:35 PM
latin,latin,more latin

@betseg what does that mean?
came, gone, dunno?

veni means i came, vidi means i saw, and dunno about the last one

That `i`

that ı

veni vidi vici: I came, I saw, I conquered.

6:46 PM
I have to say, the SO top bar is ugly af

Hehe
:PJY was supposed to be :P if it weren't for my friend over here >_>

You can edit messages you know.

CMC: Expand a string: `string` -> `sttrrriiiinnnnngggggg`, `foo` -> `fooooo`

... After which I event
Went
To troll my friend and ran out of edit time

Anonymous
@Phoenix Pretty sure we've had that

6:58 PM

CJam: `qee{~\)*}%`

Anonymous
Actually, 6 bytes: `;ru♀*Σ`

0 indexing is such a pain

Anonymous
I might be dumb

Python:
```def f(s):
r=''
for i in range(len(s)):r+=s[i]*i+1```

Anonymous
7:00 PM
Nope, the enumerate way is longer by two bytes: `ñ⌠iu*⌡MΣ`

CJam, 10 8 bytes: `Sq+ee::*`

Anonymous
@totallyhuman Nope. Get rid of the triple backticks, highlight all the text, and hit ctrl-k

APL, way too many bytes: `{↑,/⍵⍴⍨¨⍳⍴⍵}`

`n=1;o="";for i in input():o+=i*n;n+=1`, if I remember the way blocks work with semicolons.

Anonymous
47 bytes as a function: `lambda s:''.join(s*-~i for i,s in enumerate(s))`

7:01 PM
@Phoenix MATL, 6 bytes: `tgYsY"`

I think you can golf by using a recursive function

>_> consider me out-golfed

7:06 PM
@Adnan I don't think the `f=` counts.

it does because you are referencing it in the function

yea, it's recursive
nice golf tho

Ah, I didn't notice :P

JS, 42 bytes: `s=>[...s].map((c,i)=>c.repeat(i+1)).join`` `

user165474
lol I have +-0 rep change for UTC today right now :P

7:16 PM
@HyperNeutrino Make that +10 ;)

that's the usual case for me
I got +10 today, from one upvote. The Java answer got 6.

user165474
yay

user165474
The funny thing is that I lost 120 rep from deleting an answer and giving a bounty today (well actually last night but UTC time)

1.5 years ago, most of the days would have resulted in a net +0 rep for me, now that I became better at golfing and started answering more, it's less common to see a +0 rep change

@Phoenix Brainfuck, 24 bytes: `,[<<+[->+>.<<]>[-<+>]>,]`

user165474
7:19 PM
The last time I got +0 rep was April 30. I was close on May 3 and 6 with only +5

user165474
and onvm i have +15 now ?? lel

user165474

The last time I got +0 rep was on April 27
I fear I will get a +0 day quite soon due to inactivity

user165474
I will always visit PPCG at least once a day even if I don't do anything, just so I can get Fanatic eventually :P

7:33 PM
1

Challenge Given an integer, Q in the range -(2^100) ≤ Q ≤ 2^100, output the number of digits in that number (in base 10). Rules Yes, you may take the number as a string and find its length. All mathematical functions are allowed. You may take input in any base, but the output must be the len...

@KritixiLithos With AGL: `⍳∘≢é⊢`

@HyperNeutrino how do you decide if a state is a GoE state?

7:57 PM
3

The task: Output a value for x, where a mod x = b for two given values a,b. Assumption a and b will always be positive integers There won't always be a solution for x If multiple solutions exist, output at least one of them. If there aren't any solutions, output nothing or some indication tha...

I feel like the fibonacci question has grown rather unclear as the site has grown. Should we do something to make it clearer?

@HyperNeutrino The reason I donated that challenge is because it wasn't ready and would take a lot of work to make it so. Since it has been posted largely unchanged I wouldn't expect answering it to be easy - a brute force solution would be almost impossible to test in a reasonable timeframe

@WheatWizard sure, edit it!

Is my challenge unclear? If so, why? Otherwise, could it please be reopened?

Sandboxing helps.

8:12 PM
"please use a .ogg or .mp3" - eh, no. No no no no. Both are very complex file formats that would pose a major part of the challenge. We'd spend ten hours reading on how the format works, then 100 bytes outputting an incompressible 30-byte file header, then ... I'm not sure. I think that MP3 works in the frequency domain??? One of the codecs for ogg is FLAC, which would let us have to compute the sine wave, but...

@JanDvorak what should I say instead?

2 hours ago, by Jan Dvorak
Normally just raw bytes that can be fed to aplay are allowed

@JanDvorak edited.

Is this clear?

2

8:20 PM
Java question: I'm trying to figure out how to organize my KoTHCommServer so people can submit their KoTHComm frameworks. Do you simply have people submit a github repo link/path to a particular class, and I compile the class and instantiate it (using reflection)?
@WheatWizard that looks far better to me

Oh, wait, there is a link?

we were just talking about it :)

now it is :)

I am amazing
I manage to attract downvotes in the sandbox. Mainly for imperfections in my challenges. Makes no sense as it was sandboxed to work out the bugs

8:28 PM
Thats what downvotes in the sandbox are for.

^
meta downvotes in general mean something completely different

I've changed my votes several times in the sandbox

I thought downvotes in sandbox meant the challenge didn't have a chance to live?

@JanDvorak Same.

Probably depends on the person.

8:30 PM
It is how I use them...

no, it means that it's not ready in its current state

But I downvote to let people know that I would VTC if posted as is

I feel like it should be no hope to live. Because it is quite clear it is not ready as it is in the sandbox.

I don't think people downvote because it needs minor fixes, usually it is because the question is far from ready.

yeah, it depends on the distance-to-ready

8:32 PM
Depends on context too. If someone posts a sandbox challenge saying "looking for feedback on this far from ready idea" I wouldn't downvote it just comment, but if someone's looking to post to main soon I'd downvote and comment, then remove the downvote when it's resolved

I've posted sandbox posts to main that received 0 upvotes in the sandbox and they've done decently well

I've also had it go the other way where a +6 in the sandbox completely flopped

Best to pay most attention to the comments.

was it a KoTH?

8:35 PM
I challenge anyone to a duel. I am looking for a challenge to duel with but am thinking about a 50 rep duel using newline

@NathanMerrill No but similar

I use sandbox downvotes as a coup de grace of sorts, which is weird because it's not all that effective as a coup, or even grateful.

@Christopher Whats the question? I'm always down for a duel

@WheatWizard Finding one but I want to use newline as the language (choose the weapons thing)

Would we both compete in newline?

8:37 PM
@WheatWizard Yes.
I will be adding one feature so it will be NC most likely
(Ascii output)

Ok find a challenge you think is possible and I'd be willing

-2

Your challenge is to find the file extension of a provided filename. Example I/O: hi.txt -> txt carrot.meme -> meme lol (undefined behavior) what..is..this..file -> file

Anonymous
@programmer5000 Please stop posting challenges if you're not going to put any effort into making them clear.
2

He did put some effort ... after we doused him with CVs
2
Oh, I missed the new one is from him as well
Well, this one seems clear enough, just ... boring, IMO
I hope you don't mind me answering?

8:53 PM
that split lol

Yeah, normal / abnormal golfing languages :-)