« first day (2656 days earlier)      last day (624 days later) » 

12:06 AM
0
Q: Circular Limited Sums

BubblerChallenge Let's imagine an N-tuple of integers between 0 and M inclusive, and let's call it F. There are (M + 1) ** N possible Fs in total. How many such Fs satisfy all of the following inequalities (index is one-based)? F[n] + F[n+1] <= M for 1 <= n < N F[N] + F[1] <= M Write a program or...

 
12:22 AM
@ASCII-only idea: make programming language that is just NN taking in text and doing expected output
 
@Downgoat >_> i was actually intending to kinda do this
 
@ASCII-only brb creating gh org
 
@Downgoat link. but i haven't even figured out how to set up the dependency correctly yet
 
@ASCII-only what language, c9 is still loading
 
@Downgoat Python
 
12:34 AM
@ASCII-only if you have not start yet do reccomend rust, go, or swift 10/10 highy reccomend
 
@Downgoat the english parser is in Python though
 
:| there is only one file
 
@Downgoat yeah because i can't set up dependency properly
 
12:55 AM
@ASCII-only you can do python from rust (can you provide c9 perms)
 
1:29 AM
Best comment NA cc @ConorO'Brien
> tf_client
> HL2 client/server game specific stuff
thanks valve
(filename is actually hl2mp_client.cpp so it was just a lazy copy-paste from some ancient revision of TF2 LOL)
Oh dear it gets worse
> allocate a CBaseTFPlayer
that's not even the right class name
> can't load games in CS!
???
 
at least they are comments unlike clang/llvm source code
 
File also contains the best way of preventing format string attacks, which is to replace any percent signs with spaces
 
@quartata :O this is genius
 
I just found this file because Bot_RunAll() is called from here and tbh I'm not entirely sure why yet
anyways
@ASCII-only valve doesn't fuck around
just cut it off right at the source
 
1:53 AM
@quartata the source engine?
 
not an intentional pun
 
2:44 AM
Yay VS is updating
 
 
2 hours later…
4:34 AM
@Downgoat help can you draw chocolate eclair svg
 
@ASCII-only why
 
@Downgoat for new project no reason at all
 
sorry have final :(
 
@Downgoat ouch, good luck i guess?
 
hopefully, it's european history final on quotes from 1200 page textbook :P
 
4:45 AM
:|
rip
i don't think any amount of luck is enough
 
5:25 AM
 
5:57 AM
@anyone good with CIL: Anyone know the difference between ldc and ldind? (load constant and indirect load)
 
6:22 AM
@ASCII-only CIL = Captured Iguana Lair?
 
@Downgoat yes. how did you know
 
@ASCII-only i hack asis
Absolutely Secret Iguana Service
 
now you just have to figure out what loading a constant iguana means
 
@ASCII-only oh a constant iguana is one that does not change color (i.e. no camoflauge) right
 
@Downgoat ah i see
 
 
1 hour later…
7:57 AM
0
A: Sandbox for Proposed Challenges

Hatshepsuteditor-golf matrices Goal Produce this diagonal matrix in a text editor: 0000000000 0100000000 0020000000 0003000000 0000400000 0000050000 0000006000 0000000700 0000000080 0000000009 Winning criterion Fewest keystrokes wins Rules Need to do it in a text editor All pre-existing packages a...

 
8:14 AM
0
A: Sandbox for Proposed Challenges

Kevin CruijssenDetermine Season code-golfnumber Introduction: In Europe and North America, the seasons are divided like this: - Spring: March, April, May - Summer: June, July, August - Autumn: September, October, November - Winter: December, January, February In Australia and South America however, the seas...

 
 
2 hours later…
10:13 AM
0
Q: Assign Airliner Seats

AdámInspired by last week's APL lesson. Given an uppercase 2D seat map and a 1D list of customers, return the seat map and the customer list but modified as follows (to indicate occupied seats and seated customers): For each unique letter in the input passenger list, lowercase that many (or all, if...

 
10:43 AM
0
Q: Do answer on meta pointing to a specified situation flow to the whole question?

l4m2 You're talking semantics. The question title is Is document.body reading your source code? and the accepted answer with (currently) 16 upvotes says it is. – Jo King The exact answer he pointed was Extracting a JavaScript program from document.body seems to me to be a direct analogue. Th...

 
:| this is weird
The people who made Glitch (a MMO) turned into Slack, and the Glitch domain is now glitch.com (the thing by SE people)
 
 
4 hours later…
3:05 PM
0
A: Sandbox for Proposed Challenges

Magic Octopus UrnMinimize a Number in Brainflak Given a number, write a piece of code in any langauge that outputs Brainflak code, which when executed, outputs that number. You will be scored on how small the resultant Brainflak code is on average for a test set of 100 numbers between -10**32 < n < 10**32, rando...

 
@MagicOctopusUrn I'm afraid that's a dupe... and why koth?
 
hi all
I have been in the wrong chat room for hours!
 
@Anush Here?

 The 2nd Monitor

General discussion about codereview.stackexchange.com - Welcom...
 
been a while since someone has made a joke at CR's expense
 
3:22 PM
I was in ppcg-gaming it seems
is there a way to tell what the longest quiet period in this chatroom has been over the last year, say?
 
Is there any way to tell which chat room is the main one of a given SE?
 
@Adám no
 
@Anush If you're any good with SQL, you might be able to use the TNBDE (The Nineteenth Byte Data Explorer) to find out. This graph (be sure to click 'Run') seems to indicate that this room has never been silent for a full UTC day since sometime in 2014.
 
You could go to Meta, and find the post asking what to call the chatroom.
 
if there is such a post
and there's no guarantee there is.
 
3:26 PM
@El'endiaStarman Should be pretty easy with a self-join
 
@Adám Ask users there.
 
When isn't there one?
 
@El'endiaStarman interesting.. Maybe it could be a CRC :)
 
Only during the first couple days of private beta.
 
Fun fact: a lot of sites' "main room" aren't actually the main rooms
 
3:27 PM
@Adám well, if it says "general discussion" or has a non-serious description, then it's pretty likely the main chat room...however, over SO, you're pretty much out of luck (I don't think there's even a main chat room there)
 
Use the site selector to go to chat rooms specific to that site and pick the one that seems to have the most messages.
 
@Pavel there're some public betas I've seen that don't have a "main room" or even a chat prefernce hhe
 
@Anush Searching the chat log for "freeze" or "frozen" or the like shows several times in 2014 and earlier that the room froze due to inactivity
 
You can find their frozen or deleted remains if you have 10k
 
@EriktheOutgolfer Perhaps one of Lounge<C++>, SOCVR, or Tavern.
 
3:28 PM
you can find frozen remains even without 10k
 
IIRC Seasoned Advice made their own main chat room instead of using the default one provided.
 
@user202729 like, "SO Tavern"?
 
I think Webmasters did as well
 
note I'm talking about chat.SO, not chat.SE/SO
 
Actually Tavern on the Meta is a meta.SE chat room.
 
3:29 PM
SO Tavern is dead, we don't talk about it
@user202729 There are three Taverns, one for each chat host
Plus about three "Meta Stack Exchange" rooms here
 
"we don't talk about it" kind of implies something disturbing is true...
 
@AdmBorkBork how long does it take for that to kick in?
 
Anyway. Because Meta.SE is not a "normal" Q&A site...
@Anush I think 7 days. (read the chat help)
 
@Anush 14 days of inactivity (other than feed bots) for public rooms, 7 days for private rooms.
 
3:31 PM
7 days is also automatic deletion of public rooms (if they haven't ever been active)
 
Could have sworn a third one had been autogenned
 
Actually, for private rooms, a mod has to keep it unfrozen. That change was made sometime last year, I think, to prevent regular users from having their own private rooms. (E.g. user chats with a mod for whatever reason, discussion resolves, mod leaves, user invites others to chat.)
 
@quartata room filtering doesn't work like that...
 
?
Works for me
@El'endiaStarman yeah. Also regular users that are made ROs will be removed at the end of the day
 
you don't search for the room's name, instead you go where it says "a list of rooms about"
 
3:33 PM
@EriktheOutgolfer ...but I wanted to search for the room's names
There are actual rooms here with MSE as a parent, that's not what I was searching for
 
3:53 PM
so.. ultimate tic tac toe
any challenges about that yet?
 
Yes, the one I linked to you
 
oh you linked in another chatroom!
thanks
you put a lot of effort into that question!
I am very impressed
 
Thank you :)
It was one of my first, and my first koth challenge so I really wanted to get it right
 
It's great.. I am thinking of an endgame variant
so the challenge is to completely solve the game from the largest number of unfilled squares possible
is that makes sense
if it doesn't, I will explain :)
 
Mostly. What do you mean the largest number of unfilled? Would you repeat until it can't solve anymore?
 
4:11 PM
CS question.. How many vertices are in a complete 3-ary heap of height h
(if you don't mind)
 
What is a "complete 3-ary heap of height h"?
 
I know some of those words
ninja'd
 
Most of that makes sense to me, but I'm not sure about 3-ary. Does that mean each node has 3 children? I don't see how that could make a heap
 
see link above and yes
 
4:13 PM
Oh, you're looking for a sum of a geometric progression.
 
So really a trinary heap is no different than a trinary tree, at least in the shape/number of nodes
 
yes you are right
 
Because a heap defines the IO operations on the whole tree
So it would be sum(3^k, for k in range(n)), which can be expressed nicely, I just don't know how
 
1 + 3 + 9 + 27 = 3^0 + 3^1 + 3^2 + 3^3 = (3^4 - 1) / (3 - 1)
 
1/2 (3^(n + 1) - 1) ?
 
4:16 PM
Or, in trinary, 1111 = (10000 - 1) / 2 = 2222 / 2.
 
@El'endiaStarman Sooo, (n^(k+1) - 1) / (n - 1)
 
is my formula the same?
 
@Anush I believe so
 
(3^4 -1)/2
 
@DJMcMayhem Where n is the base and k is the number of terms, yes.
 
4:19 PM
Man, it's clearly been ages since my calculus class. I barely remember how to do sums of (arithmetic/geometric) series'ss
 
I worked out the above formula on my own during Spanish class once in my sophomore year of high school (I think) by working in a different base like what I showed. It's relatively easy to re-derive it.
 
@El'endiaStarman So mathy question: If arithmetic means each new term is plus a constant, and geometric means each new term is times a constant, what would you call each new term is raised to a constant?
 
@DJMcMayhem I'm not aware of a specific term for that; it's not often useful.
You could probably call it an exponential progression though.
 
It really blew my mind the first time I realized that all basic math functions are iterated or negated forms of each other, and everything boils down to incrementing. Like, addition = iterated incrementing, and multiplication = iterated addition = iterated iterated incrementing and exponentiation = iterated multiplication = iterated iterated iterated incrementing and so on
I think I saw that in a numberphile video explaining Knuth Arrow Notation and Graham's number
 
That breaks down when you get to exponentiation though if you're working with anything other than positive integers.
E.g. what is 1.5 ^ 1.5?
Or everyone's favorite, i^i. :P
 
4:29 PM
@El'endiaStarman Well if you're including the negated forms it'll break down much before that. If add subtraction, you need to add negative numbers for it to make sense. If you add division, you need to add integers. Then once you get to exponentiation/roots/logs, you need to add complex
Each new iterated operation adds a new set of numbers needed for the system to work
 
Fun fact: complex is where that ends.
 
Which never occurred to me before
@El'endiaStarman Oh? How so?
 
You actually start losing properties moving on to the quaternions (you lose commutativity) and the octonions (I think you lose associativity).
 
You're saying that power-towers don't require doubly complex numbers? :P
 
Nope. Any elementary function will turn complex numbers into complex numbers.
 
4:32 PM
@El'endiaStarman I've actually never heard those terms before. After a quick read on wikipedia, I'm surprised the next extension after complex is 4-dimensional, not 3-dimensional
 
@DJMcMayhem Indeed! The guy who discovered/developed quaternions, Hamilton, was trying to do the same for 3D numbers. He eventually realized that was impossible and the next step was 4D.
 
It's because it's powers of 2.
 
@El'endiaStarman Is there a term for the set of functions that turn integers into integers?
 
@DJMcMayhem Addition, subtraction, and multiplication. Even division will make you need rationals.
 
@El'endiaStarman And exponention.
 
4:36 PM
:/ I forgot that integer doesn't include rationals
 
@wizzwizz4 Nope. 2 ^ -1 == 1/2.
 
Wait, no, negatives.
Ninja'd.
And rationals can make complex.
And complex can make the world burn.
 
Exponentiation on integers requires rationals. Exponentiation on rationals requires reals (2 ^ 1/2). Polynomials on even just the integers requires complex (x^2 = -1).
Actually, exponentiation on rationals requires real + complex because of (-1) ^ 1/2.
@wizzwizz4 There isn't a corresponding algebra for 16 though.
 
@El'endiaStarman Ok, so after actually remembering the correct number sets, I'm going to rephrase my question. Which functions map real numbers to real numbers?
Also, random thought: It seems like negating a function will require a larger set than iterating a function, e.g. subtraction (negated addition) requires a larger number set than multiplication (iterated addition).
 
+-*/, exponents with base non-negative or exponent integer, trig functions, and log with positive argument. I think that covers it.
 
4:44 PM
@El'endiaStarman Not yet...
Or has it been proven that there isn't one?
 
My gut is that it has been proven that there isn't one. "Algebra" has a specific meaning here.
 
Nevermind.
 
@user202729 I think you were right.
 
Oh here we go:
In mathematics, Hurwitz's theorem is a theorem of Adolf Hurwitz (1859–1919), published posthumously in 1923, solving the Hurwitz problem for finite-dimensional unital real non-associative algebras endowed with a positive-definite quadratic form. The theorem states that if the quadratic form defines a homomorphism into the positive real numbers on the non-zero part of the algebra, then the algebra must be isomorphic to the real numbers, the complex numbers, the quaternions or the octonions. Such algebras, sometimes called Hurwitz algebras, are examples of composition algebras. The theory of ...
 
> There are only four normed division algebras (algebras where division by nonzero elements is possible) over the reals: the reals themselves, the complex numbers, quaternions, and a strange (alternative but nonassociative) algebra called octonions.
 
4:47 PM
Oh, ok. I should stop pretending to know maths.
That's the main region of maths I haven't touched on, though, because I thought it was a useless extension of the complex numbers.
 
Ok, we have about 3 users with green profile image here.
I don't know either...?
 
Yeah, quaternions are mostly useful for 3D rotations and octonions barely get used for anything.
 
Is there an operation with complex numbers that's undefined but that becomes defined with quartions?
 
Not that I'm aware of.
 
In which case, I'll hold the view of them that most people hold of trigonometry.
Until corrected.
 
4:54 PM
I'd say that both cases are an instance of a specific narrow branch (trigonometry, quaternions/octonions) that's part of a much larger field with loads of interesting stuff (geometry, group theory).
 
@El'endiaStarman I was just corrected.
 
This is why I love talking to @El'endiaStarman
I always learn something new and interesting :)
 
Couldn't you have waited until I didn't have a few hundred cool projects I wanted to do?
Now I need to research it!
@El'endiaStarman Oh, you're back!
I hadn't noticed somehow.
 
@wizzwizz4 Yeah, I drop in every now and then.
@wizzwizz4 Admit it, you will always have a few hundred cool projects you want to do.
 
CMC: Output this:
         A
        B C
       D E F
      G H I J
     K L M N O
    P Q R S T U
   V W X Y Z a b
  c d e f g h i j
 k l m n o p q r s
t u v w x y z
 
5:18 PM
@El'endiaStarman Sometimes I don't think of any and they're in the tens.
@DJMcMayhem I call the cat program.
 
5:33 PM
V, 30 bytes: Try it online!
 
0
A: Sandbox for Proposed Challenges

JMigstHow Many Cards Can You Play This Turn? code-golf math Given a deck of cards L, where each card has an nonnegative integer mana cost, and two nonnegative integers x, representing the mana you have this turn, and n, representing the number of cards you draw from the deck, output the average highe...

 
6:09 PM
@DJMcMayhem PowerShell, 79 bytes -- 9..0|%{' '*$_+"$([char[]](65..90+97..122)[$j..($i=$k*($k+3)/2)])";$j=$i+1;$k++} Try it online!
Several neat golfing features present.
Compact form of triangular number calculation, abusing the default $OutputFieldSeparator for arrays (which is a space) to give us the space-separated strings essentially free, abuses the fact that indexing past the end of an array is $null
 
Are you inclined at present to present these golfing features present?
(Chat mini-poll: how many different pronunciations of "present" in the above sentence?)
 
@El'endiaStarman 2.
 
Same here, I think 2
 
Two for me as well. The middle one is different from the first and third for me.
 
Same
 
6:13 PM
pREH-sent / preSENt / pREH-sent
 
@El'endiaStarman 2
 
@wizzwizz4 Yeah, that.
 
I need to learn API at some point.
Also APL.
And C++.
And now Quarterions.
 
ngn
@El'endiaStarman is the third one "pre-sent", like sent in advance?
 
@ngn I think it's "that are here".
Are you inclined atm to show us these golfing features that are [t]here?
 
ngn
6:23 PM
@wizzwizz4 I think that too but the answer 2 is too obvious and boring :)
 
@ngn I agree. Now 4 would be an interesting answer.
 
@ngn I too think that, posting two, I posted one too many solutions.
 
@wizzwizz4 You called?
 
Buffalo buffalo buffalo.
 
@Adám I haven't even read through the existing lessons!
I've added an xkcd link to ^^^^ to make the reference more explicit.
 
6:28 PM
@AdmBorkBork Three word classes, one pronunciation.
 
@AdmBorkBork Proper noun [which] Proper noun verb[,] verb Proper noun.
@Adám It might just be noun verb noun, as opposed to Proper noun verb.
I suppose it could be noun verb Proper.
 
ngn
@wizzwizz4 ah, like the numbers in my fav conlang :)
 
No one else wants to do DJ's alphabet CMC?
 
@AdmBorkBork So, I win by default with the naive cat program?
I'm sad now.
 
ngn
@AdmBorkBork I tried but couldn't do it in <30 bytes
 
6:36 PM
Neither could I ...
 
Have any of you noticed that the new SE layout is visible here? At least looks like it
 
Oh, never mind, TommyD did it. And quite well, actually!
 
Woah, it works so bad
 
@Soaku Erm... Do you mean it's good, or it doesn't work?
 
@wizzwizz4 You reply to the first or second message?
 
6:39 PM
@Soaku Second.
 
@wizzwizz4 It works, but... just bad.
 
Ok. So, I should take you literally more often.
 
> Never tell jokes to kleptomaniacs. They always take things literally.
8
 
@AdmBorkBork Missing comma.
 
Depending upon your interpretation.
 
6:43 PM
@wizzwizz4 You're into retro-computing, right?
 
@ngn You're welcome to do it in >30 bytes
 
Or even =30 bytes
 
@Adám Yeah...
(I can't exactly say "no" to that!)
 
I'd love to see an APL solution
 
ngn
@DJMcMayhem in k, many bytes: ,/'(|,\10#""),'(+\!10)_a,_a:`c$32,'65+!26
 
6:46 PM
@wizzwizz4 It may amuse you to hear that I found a text-based resource management game on the virtual disk tape drive of an APL\360 system for the IBM System/360.
 
@Adám What's it called, and is it public domain?
If it's public domain, can you upload it to archive.org?
 
@wizzwizz4 It is called KINGDOM (lowercase didn't exist in APL\360 because they needed the positions for APL glyphs). I've GitHub'ed both the original code, my port to modern APL, and an adaption to run as a website using MiServer.
@wizzwizz4 I plan on writing a blog post about the conversion processes in the near future. And on making the game playable online from our server.
 
@Adám Sounds cool!
Personally, I don't think APL should count as Retrocomputing, since they made it good and didn't throw it away.
By that metric, modern FORTRAN should count as Retrocomputing, which I think is appropriate.
 
@wizzwizz4 Right, but the neat thing is that even the AJAX-based website uses the original source code for the actual game mechanics, with just minimal insertions to redirect stdin typewriter-in and stdout typewriter-out to AJAX.
 
@Adám ... Wow.
That means that any APL program can be...
I just bumped APL up one space on my "programming languages to learn" list.
 
6:59 PM
@wizzwizz4 … ported 50 years ahead with minimal effort. Which other language can do that?
 
@Adám C.
 
contenteditable + execCommand behaves very differently between browsers. Is there any way to get it in a more standard way? (I'm making a WYSIWYG markdown editor...)
 
@wizzwizz4 C isn't even 50yo yet, and good luck doing "minimal effort" porting of 46yo C code to compile in a modern compiler.
 
@Adám English :P
 
@DJMcMayhem êcsôðlîce wægn tunge onwendan bæc ðrêal.
 
7:08 PM
@AdmBorkBork That looks a tad over 50.
 
Just a touch. ;-)
 
But try listening carefully to how people spoke in the original Star Wars. And that's only 40 years old.
 
ngn
some hippie slang could prove DJ wrong :)
 
Sure, but there's a lot of slang from, e.g., the 1920s that is still relevant today. Say something is the "bee's knees" and you'll still be generally understood.
For example.
 
The "bee's knees" is 1920s slang?! Yeesh, these oldies need to get out of our online chat rooms!
 
7:28 PM
@DJMcMayhem 05AB1E abomination, 14 bytes: AuAðÐJā£»Sðý.C (uh, I can't do anything about that multi-ping side effect)
(note: it's not very easy to see whether it's been already posted)
 
Wow, that's really short
 
well, the output is basically a horrible abomination of leading and trailing whitespace
 
05AB1E golfers are really lucky to have .C in this context.
 
7:48 PM
0
A: Sandbox for Proposed Challenges

BeefsterThe N Queens Problem, but with Fairy Chess Pieces popularity-contest chess Fairy Chess is a sort of generalized chess that allows unconventional pieces. The eight queens problem is a classic problem where you have to put 8 queens on a chess board such that no two queens threaten each other. T...

 
@DJMcMayhem Canvas, 23 bytes. The 0 is in the input because of a bug which I'll be fixing in a bit
bug fixed, feel free to test with the 0 removed
 
8:04 PM
Wait, what does .C do in 05AB1E do?
 
centralize, breaking ties to the right
there's also .c which breaks ties towards the left side
 
Ah, as in text manipulation, right?
 
well, a list of strings is first joined by newlines too
 
@EriktheOutgolfer how are you splitting (or whatever you're doing) the characters into lines?
 
»
that is, in 05AB1E (also, that's called joining ;) )
05AB1E is relatively easy to learn, btw, give it a try!
 
8:08 PM
@EriktheOutgolfer I meant the part of splitting the alphabets into the increasing length lines
 
"the alphabets" is actually [A-Z][a-z] {3} in regex-esque notation :P
 
I'm having trouble remembering what something's called. It's sorta like a combination of turing machine, and regex find/replace, but it's multistep...

ab->x
ax->y

aab => ax => y
 
oh it's just a builtin for splitting a string into specified lengths..
 
well, after making the string with AuAðÐJ, ā£ does the job of splitting it like that; ā pushes the 1-based indices of the string, and £ cuts the string in order with that index list
 
So, what is WW's name now?
 
8:12 PM
this also generates a lot of trailing empty strings, that's why there are many trailing lines
 
I have 11+1 bytes on reversing ~triangle numbers and checking if they're round :p
 
@Zacharý What Wizard
 
I remember the name now: (semi-)thue system/grammar (and String Rewriting System)
 
8:27 PM
@Poke Oh, beautiful.
 
8:39 PM
0
A: Sandbox for Proposed Challenges

AdmBorkBorkAlphabet Star code-golf kolmogorov-complexity Output this exact text: Z Z Z Y Y Y X X X W W W V ...

 
@NewSandboxedPosts uh, not to offend anybody, but, another alphabet challenge?
 
9:31 PM
@DJMcMayhem Charcoal, 18 bytes: G↗χ→²↘χψ¤⁺⪫⁺αβ × ⁷
 
@NewSandboxedPosts Charcoal, 3 bytes: P*α
@Neil :| did i mess up the deverbosifier again
 
no, I just couldn't be bothered to format the link
 
ah
>_> I should really do that shouldn't I? brb
@Neil Hmm. would changing the current bytecount format to include the link be fine?
nvm, done. just need to wait for Dennis to pull
 
10:21 PM
-2
Q: C++ Continuously Running Timer in Parallel with other process

FanBoyI want to write a C++ program in which I want timer/stopwatch to run continuously in parallel with other process(taking input) I've written code, But I can't figure out how can I display changing time, It shows static output till statement is recalled again Desired Output: Time Elapsed:...

 

« first day (2656 days earlier)      last day (624 days later) »