« first day (2713 days earlier)      last day (2122 days later) » 

12:14 AM
@EriktheOutgolfer which byte?
 
12:24 AM
To all brainflak gods/golfers/people: why does this loop?
 
@Zacharý ({[()]})
Once entered that loop cannot be escaped
 
Okay, BMO already fixed it, an I think I see why that loops, {...} is the relevant portion of that, right?
 
Yes, {...} is a loop.
and [()] doesn't do anything
 
perhaps you mean to do ({([()]{})})?
 
Since it's a polyglot I think it is likely meant to be dead code
 
12:34 AM
@CatWizard Yes, it is for a polyglot
 
yeah i wasn't paying attention to what the code was for
 
It's @JoKing's metagolfer output stuck onto a polyglot
 
@DestructibleLemon I wasn't much at first but then I saw <><><[]><><><><><>
 
AsI've said: BMO already fixed it.
I just pray that the code in some of the languages work...
 
12:51 AM
@NewMainPosts I really don't want very simple challenges to get on HNQ. For whatever reasons.
 
1:02 AM
@NewMetaPosts Post a new message with better link text (then star it) is much easier than asking a mod to edit the link text right?
 
1:34 AM
PSA: Stylish is spyware
 
@quartata eh it seems to be disableable and stylish is useful enough for me to bother clicking my left mouse button twice
 
@DestructibleLemon oh so thats why sylish looked different & was named differently on windows
oh stylus has a linter that doesnt warn on !important. That's enough of a reason to switch
 
 
4 hours later…
5:46 AM
0
Q: Convert Numbers to Letters, and vice-versa in a string

Noir AntaresBased on a list of numbers and their equivalent letters, take a string input, replace the characters of that string with the equivalent number/letter and output the result. List 1 = a 2 = b 3 = c 4 = d 5 = e 6 = f 7 = g 8 = h 9 = i 0 = j Input thisisastring1124 ...

 
5:58 AM
Has anyone seen Mego recently
 
-2
Q: why current date is showing next date in php?

A JI want to get current date of the server but it showing me next date from the current date, why it is happening I am surprised. I am trying with following code: date('Y-m-d')

-1
Q: can't install any packages using apt-get in python

user81437on Ubuntu, I've been trying to install packages for days! but I keep having this error, I read every blog but Ican't seem to figure out the right solution. I think it's a python-version issue. my default version is python 3.6 . and the pachakes are compatible with python2.7. i tried changing the...

 
6:19 AM
@Downgoat No I have not
 
6:33 AM
Google: Makes world-leading genius AI that solve world peace
 
7:07 AM
hi... any algo people here understand the suggested dynamic programming algorithm at cstheory.stackexchange.com/questions/41132/… ?
 
ngn
7:30 AM
@Anush an algorithm containing the phrase "I bet [...] you have a recurrence relation" is hard to understand :)
 
@ngn right!!
At least I find it hard to understand
 
ngn
@Anush if you assign weights for the edges instead of the vertices, e.g. by postulating that w({v0,v1}) = w(v0) + w(v1), you could use this algorithm: en.wikipedia.org/wiki/…
(I'm not claiming it's the asymptotically fastest.)
 
interesting
I guess that is worse than O(n^2) right?
 
ngn
@Anush yes
 
0
Q: First Last Last First

WretchedLoutChallenge The task is simple. Given an array and a first and last value: Return the first of the last after the first, and the last of the first before the last. Input Two positive integers Array of positive integers Output Index of answers, in order Output -1 for each output that does n...

 
7:45 AM
@ngn maybe I should pose it as a fastest-code challenge :)
 
ngn
8:01 AM
@Anush oops, above I meant: w({v0,v1}) = |w(v0) - w(v1)|, not w(v0) + w(v1)
@Anush up to you, but it doesn't look easy to implement, so there may not be many takers
 
8:17 AM
@ngn well. there is ease of implementation and there is the question of whether there is actually an algorithm to implement
I mean, do you believe the algorithm?
 
ngn
@Anush the one from wikipedia - yes; the dynamic programming algorithm from the comments - I'm not convinced
 
right.. I meant the one from the comments
 
8:34 AM
@ngn Can you help me? I have way too much duplication of code in
0
A: First Last Last First

AdámAPL (Dyalog Unicode), 42 bytesSBCS Anonymous tacit infix function. Takes var1,var2 as left argument and the array as right argument. {⍸<\(⍵=⊃⌽⍺)∧∨\⍵=⊃⍺},{⍸⌽<\(⍵=⊃⍺)∧∨\⍵=⊃⌽⍺}∘⌽ Try it online!

Really, I need the Over operator (). Then it would have been just ⍸¨f⍥⌽{⍵⍺}f←{<\(⍵=⊃⌽⍺)∧∨\⍵=⊃⍺}
 
ngn
@Adám "Return the first of the last after the first, and the last of the first before the last." - er... what?! :)
 
@ngn IKR. Just read my APL code, and you'll understand.
 
8:50 AM
0
Q: 2D Array Middle Point

Noir AntaresAssuming a 2D array except [1xn] that results in an odd number of elements is represented as follows, find the midpoint index: Example: Input is a 3x5 2D array [0,0] [0,1] [0,2] [0,3] [0,4] [1,0] [1,1] [1,2] [1,3] [1,4] [2,0] [2,1] [2,2] [2,3] [2,4] In this case midpoint index...

 
Can someone reopen the Husk chatroom? I need help with golfing
 
ngn
9:04 AM
@Adám it took me more time than it should to even understand the problem... anyway, here's a shorter expression that probably can be golfed further: {⊃{(⊃⍵~⍳⊃⍺)(⊃⌽⍺∩⍳⊃⌽⍵)}/⍸¨⍺=⊂⍵}
 
@ngn wow you dared to use ?! instead of ‽ in front of Adám...nice
@EsolangingFruit just a bit of a check: DJ
hm, he's not here
 
9:43 AM
@ngn It doesn't resemble my solution at all, don't you want to post {(⊃⍵~⍳⊃⍺)(⊃⌽⍺∩⍳⊃⌽⍵)}/⍸¨⎕=⊂⎕ yourself?
 
ngn
@Adám oks, I'll post it a bit later
btw, now I see I missed the obvious (A)(B) -> (A),B
 
@ngn Yeah, it's a scalar, duh.
 
can somebody verify whether codegolf.stackexchange.com/a/167882/3103 is a valid solution
for a language more verbose than Java it's way too short, and i have a feeling i may have misunderstood something
oh, i see
yeah, it's wrong
 
10:02 AM
@KonradBorowski more verbose than java? The answer's got .. and a map function.. You'd never get those straight off for free in java
 
yeah, i guess .. is nicer than IntStream, but literally everything else is more verbose
 
really all you'd have to do is somehow prepend 1 though no idea how ungolfy that'd be
 
it's 56 bytes now
 
@EriktheOutgolfer How can you do it in 1 byte? .) is as short as I can get it.
 
from 39 bytes to 56 bytes
|n|(0..n).map(|n|format!("{}{}",n,n+1).parse().unwrap())
it is verbose, as i said
 
10:05 AM
@cairdcoinheringaahing if both n and n+1 are in the input, then it's only ~
maybe you meant that only n is in the input
 
i sorta depend on type inference later on in test code with parse here however
not sure if it's acceptable
 
in which case it's 3 bytes: either .~) or ~.)
 
@EriktheOutgolfer Yeah, forgot that Golfscript doesn't eval input :/
 
as i do println!("{:?}", f(10).collect::<Vec<i32>>());, where i specify i32 explicitly, not requiring me to specify the type for parse method
to print the results
 
that's yet another reason why it has declined in usage :P
 
10:07 AM
Brilliant way of waking up in the morning: your dog standing over you with your crushed glasses in his mouth
 
@KonradBorowski there's this but it doesn't really have a clear consensus
 
@dzaima Okay, I suppose Rust also has ArrayList in prelude, as opposed to having to import java.util.*, but otherwise more verbose
HashMap is like std::collections::HashMap however and it's not imported by default
i'm looking forward to Rust 2018, where you will be able to use external dependencies without using extern crate declarations, but at the same this is yet another tricky issue in terms of rules.
like tree::Map is shorter than std::collections::HashMap, but at the same time you need to declare a dependency in another file
 
 
2 hours later…
12:35 PM
0
A: Sandbox for Proposed Challenges

Jo KingSort of numbers code-golf sorting unicode Within the recesses of Unicode characters, there exists a block of 64 characters (0x2150 - 0x218F) called Number Forms, which consists of characters that have numerical values, such as the roman numeral Ⅻ, vulgar fractions like ⅑ or ↉, or weird ones like...

 
12:54 PM
@NewSandboxedPosts Perl 6...
 
1:14 PM
TFW polyglotting results in you finding a bug in the interpreter
 
 
1 hour later…
3:04 PM
@DJMcMayhem (or any mod), you can move the entire conversation in here to Polyglot Development
 
3:22 PM
@Zacharý Sure, give me 5 minutes
 
@Zacharý Does it need to be moved there? It's not cluttering anything where it is and I don't really think it needs to be in that room.
 
@Zacharý by entire conversation, do you mean everything from the first message on?
 
@DJMcMayhem Past and including this message can be moved
@CatWizard Well, it turned into talking about development of polyglots after I talked about how a Befunge-93 interpreter I previously used screwed us (fixed now) with the size restriction
 
Bout to set a new record....
 
@DJMcMayhem What do you mean? Amount of messages moved?
 
Thanks!
If I typed "@Chance" in one of the moved messages, it won't ping him, right?
 
4
Q: In for a bumpy ride

Cat WizardYour task is to write a computer program or function that takes a list of integers and determines if they are a "zigzag". A sequence is a zigzag if and only if the numbers alternate in being larger and smaller than the number that comes before them. For example \$[1,2,0,3,2]\$ and \$[4,2,3,0,1]...

 
@JungHwanMin sorry, you got ninja'd over there :P
Can the empty list as well as singleton lists be considered a zigzag? (Vacuous truth) — Erik the Outgolfer 2 mins ago
On the same line as @EriktheOutgolfer, what about lists with length 1? — JungHwan Min 38 secs ago
btw, if the length ought to be at least 2 or lists with length ≤1 are considered zigzags, my solution won't have to get longer :P
oh wait...yay
 
3:59 PM
 
@JoKing grats for 10k :)
 
4:16 PM
@EriktheOutgolfer I think they had 10k multiple times...
 
um, what? that's unfortunate...
(bounties?)
 
No, apparently.
 
4:42 PM
bah, I wish I knew how to find what's scribbling 0x6d6f632e in random places in my address space
 
4:59 PM
Great, MathJax looks completely messed up on my phone (desktop site).
 
5:23 PM
I finally repcapped.
 
5:54 PM
1
Q: What's the complexity of my answer?

msh210I've never studied any computer science. So I've always passed over restricted-complexity questions, since I had no way of knowing the complexity of my code. Today, I decided to try and see whether I could change that. I read the tag description (as available on mobile, which I think is only the ...

 
Anyone know how to get alphuck to run via TIO's bash?
 
translate to bf, pipe it into bf
 
Can some bash wizard help with that?
 
You don't really need bash, python, perl etc can be used for all the grunt work
 
6:42 PM
@Zacharý Just do what the wrapper does.
 
@Dennis I've tried...
 
What did you try?
 
you can post the link in the chat without a paste bin
 
@Dennis /opt/brainfuck/alphuck <file-name>
@CatWizard It's too dang long
 
6:45 PM
shift enter. Character limits go away.
 
.---.
^ Yet that works
 
What doesn't?
 
^ The last language tested there (alphuck) should work, but it doesn't.
 
C# 8 gets switch as an expression rather than a statement, Python's list slicing, and a..b range syntax. Makes me happy.
 
Switch ... expression?
 
6:56 PM
That means it can evaluate to a result
 
I know, but that seems unnecessary (a little useful, maybe)
 
It's closer to an F# pattern match than a switch/case, actually
 
A thing that I saw causing a few bugs in production code is that variables declared inline by a pattern matching expression in C# 7+ are actually references which mutate the original object. IMO that is completely non-obvious.
 
@mınxomaτ Really? C# doesn't have copy constructors or anything like that, so taking a reference seems to be the only way.
 
I wouldn't expect it to mutate the object. That could be optional, e.g. obj is T varname vs obj is T ref varname.
 
7:06 PM
@Zacharý Try rm code.* before running alphuck.
 
@Dennis I got it to work: I just used .input.tio instead of code
 
@mınxomaτ What would it do if not take a reference?
 
I don't know. I'd just like an immutable variant.
 
@dzaima i don't know, map is pretty much free in Java as long you require Stream<T> as a function argument
 
@mınxomaτ C# doesn't work like that. If you need an immutable reference, you have to make the type immutable.
 
7:15 PM
I know
 
Have you been working with Rust by any chance?
 
Rust doesn't align with my brain in any way whatsoever. I tried to pick it up multiple times, but I neither want or need to anymore.
 
yeah, probably the most verbose programming language you could use in code golf
(Java is often shorter)
 
too long for shift-enter, apparently
2519 characters of regex.
 
7:54 PM
0
A: Sandbox for Proposed Challenges

Luis felipe De jesus MunozRandomizing until 0-bit Given a positive integer (K) Output a random positive integer (Y) between [K, 0). If Y > 0 Assume K = Y and repeat the process until Y = 0. Rules Input must be printed at first Output format as you wish Your program must finish. There must not be repeated numbers

 
8:34 PM
@Riker Just discovered that Rick Astley actually makes some great music. (not entierly my taste, but still, he's got a great voice. even NGGYU would actually be quite a cool song, if it wasn't overplayed so much)
 
@flawr Why do you say this now? Get rickrolled?
 
Nope, just found some of his other music on YT
but form now on, I'm gonna enjoy the rickrolls way more
 
@Pavel rust makes me love it and barf in my mouth at the same time :P
 
@Downgoat Like perl6 ... except more 50/50, rather than "Oh that's a cool feature ... WHAT IS THIS HORRIBLE LANGUAGE"
 
This is a plea for @CatWizard to change that ugly avatar :-) Please star if you see fit
17
 
8:45 PM
No
 
Please :-) It looks distressing
@flawr Funny. The voice is what I dislike the most of Rick Astley :-)
 
Is that some sort of decapitated cat? ugh...
 
9:01 PM
@Mr.Xcoder What happened to your avatar?
 
I kind of got bored of it and then, after reaching the first page of users (sorted by all time), the similarity between my Penrose Triangle and Digital Trauma's impossible object was disrupting... So I chose to change it :P Might swap from the standard avatar soon though
Regarding the other temporary one with the tree-in-front-of-the-radial-sun drawing, it just didn't feel suited to a profile pic...
 
@Mr.Xcoder Avatar suggestion:
 
9:17 PM
Lol I will consider some variation of that :) I really like it (on mobile now so I'll probably change it tomorrow) thanks
 
@Mr.Xcoder Do you actually use Xcode?
 
Yeah, I really use Xcode. In the past I used to work with it nearly everyday (being passionate about frontend iOS development), but now I only utilize it occasionally.
 
9:49 PM
0
A: Sandbox for Proposed Challenges

MegoDate Recurrences Given three non-negative integers y, m, and d (of which at least one must be positive) and a valid date, output the date that is y years, m months, and d days after the original date. The method for computing the next date is as follows: Add y to the year Add m to the month I...

 
10:05 PM
0
Q: Maximum Row, Minimum Column Equilibrium

ArcturusGiven a numerical matrix with size m x n with m,n ≥ 2, output the element of the matrix that is the result of the following algorithm. Remove from the matrix the row with the highest sum If this is not the first iteration of the algorithm, replace the column that was most recently removed in it...

 
10:30 PM
@LuisMendo what ugly avatar? btw, most avatars are glitching for me again, after a long time, so I can't see them (I see placeholders instead, and, if I try to visit the images directly, there's an error instead)
and I don't know what extension causes this yet
actually, I don't think it's an extension, although incognito works fine
I just cleaned my cache for a third time, no results >_<
also cleaned imgur and gravatar cookies
but starring nevertheless :P
 
11:08 PM
uh, hm, so, apparently, Chrome messed up with the TLS 1.3 flag's Default, so I set it to Disabled :P
 
11:26 PM
CMC: Given the expression in convenient format 10^(10^(10^(...N))), output the result in the form 10↑↑B. E.g., 10^(10^3.162) is roughly 10↑↑2.5
 
@EriktheOutgolfer It looks (at least to me) like a cat or dog with a maformed head/face. There's only a mouth where the head should be. Ugly to look at
huh, five stars already
 
@Mr.Xcoder random proposal: btw since you do swift, I've been working on a side project vihan.org/p/gitgoat which is a native iOS GH client, curious if you'd be interested in joining as a collaborator
I stopped working on it after school started but now that it's summer I want to keep working on it
 
@LuisMendo sorry, already fixed the issue :D
 
So, do you concur? :-)
 
yeah, I just couldn't determine if the avatar was changed so I couldn't vote fairly ;)
@ConorO'Brien hm, should be .5 be interpreted as a "tetration root"?
I guess Cat Wizard is the only person who can respond to his current avatar with "bless you!" :P
uh... maybe not his avatar yet, but something else (click at your own risk, still feeling nauseous and terrified) did actually change
 

« first day (2713 days earlier)      last day (2122 days later) »