« first day (2527 days earlier)      last day (2315 days later) » 

12:29 AM
so say I'm creating a challenge that involves HTTP requests to localhost
does that still count as an challenge?
 
@LeakyNun he collects rep notices
doesn't clear it for as long as he can
iirc the goal is 10k?
 
wat goal is that
 
 
1 hour later…
Anonymous
1:44 AM
@NickClifford yes, probably not
 
got it
 
1:58 AM
0
A: Sandbox for Proposed Challenges

Nick CliffordGet ERC20 token balance code-golf networking Ethereum is a blockchain platform. It has its own native cryptocurrency, ether, but in this challenge, we'll be focusing on its ability to run smart contracts. The ERC-20 standard describes an implementation of fungible tokens within a smart contrac...

 
@Adám so you gave me a list you found of ideas for gifts for my younger sis, I got a book series from the list and it has 6 books, she is almost done with them so they were a hit
 
Can anyone help me with installing grub?
 
Anonymous
@user202729 Maybe
 
sigh
someone from here
please make my name back to Leaky Nun
@Mego
 
Anonymous
@KennyLau Only a mod can do that
 
2:08 AM
ok
 
Anonymous
Also asking politely tends to work better
 
@Mego done
 
mkfs.ext4 /dev/sda8
mount /dev/sda8 /mnt
arch-chroot /mnt
(with some not-too-important commands) is what I typed.
Now... how should I run grub-install?
 
Anonymous
Make sure you have grub-install in your chroot
 
Yes, type grub-install works, but I'm not sure on which directory/partition should I call it.
just /dev/sda8 or /?
I was quite confused by the chroot...
 
Anonymous
2:12 AM
So chroot makes your system act like whatever the target is is the root dir
 
Anonymous
So you need to do ln -s $( which grub-install ) /mnt/grub-install
 
Anonymous
And then you can do ./grub-install inside the chroot
 
I installed grub after chroot, so that should not be a problem...
My question is, should I grub-install /dev/sda8 or grub-install / ? Should --force be included?
 
Anonymous
grub-install / inside of the chroot
 
Anonymous
Inside the chroot, nothing exists aside from whatever is in /mnt
 
2:18 AM
That gives (something like) "/ is a directory, cannot proceed".
 
Anonymous
Oh, you don't need a chroot for grub
 
So... exit chroot and then grub-install /dev/sda8?
 
Anonymous
Wait... Why are you using a chroot? Are you manually installing Linux?
 
Because... yes. "following the installation guide".
 
Anonymous
Oh, ok, I misunderstood. Inside the chroot, run grub-install /dev/sda
 
2:21 AM
The whole sda? Ok... would that mess up Windows boot or any other partition?
 
Anonymous
Before getting in the chroot, if you haven't already, do for i in /dev /dev/pts /proc /sys /run; do sudo mount -B $i /mnt$i; done
 
Anonymous
@user202729 Nope, Grub plays nicely with Windows
 
I hope it will figure out which partition contains Windows and does not delete important files... Should I use --force, or do I have to?
 
Anonymous
Nonono, Grub doesn't actually mess with the partitions. It just overwrites the MBR so that it gets booted. From Grub, you choose which partition to boot.
 
Ok.
 
Anonymous
2:33 AM
in PPCG Podcast, 7 secs ago, by Mego
Ok, gang. I'm going to take the helm on this revived podcast. If you are interested in being on the first episode (which will be recorded sometime in early January), ping me here (not in TNB, so I can keep stuff organized). Additionally, if you have a topic you want to discuss (or want discussed, if you don't want to be a guest), mention it here (also not in TNB).
 
3:09 AM
You know how at some point, you looked at your mom's or grandparent's phone, and they have like 50 tabs open? I have that with just SE chat rooms.
 
4:00 AM
Ok... I was finally able to figure out how to add Windows entry to grub.
Now... I'm not sure how to configure network for linux.
 
4:34 AM
Done.
 
 
2 hours later…
6:52 AM
0
A: Sandbox for Proposed Challenges

NathanielAls pr Yrck, I knw hm Hrtio Here is a link to a text file containing the script for Shakespeare's Hamlet.[to do: provide such a text file, or think of another freely available text input that leads to a wittier title.] Your task is to write a program that will compress this text, and another th...

 
 
6 hours later…
12:29 PM
0
Q: Return number n without the use of numbers throughout the code

VortexYTYou have a function named returnN(int n) (for C / C++) and that function must return n, but without the use of numbers. This is a very simple question I am asking you, and I'm sure most of you will be able to get this. I shall give you the solution that half of you have got in your head at the mo...

 
1:07 PM
CMC: given four positive integers a, b, c, d, output whether a+b√2 < c+d√2.
I would appreciate loseless algorithms, i.e. no floating points
 
Hm... looks like some multiplication with conjugate will help.
Oh... I didn't install Mathematica in Linux. Let's use TIO.
 
@user202729 I don't see how that helps
@user202729 Mathematica
 
Seems that I'm wrong...
<-> a-c < (d-b) sqrt(2)
@user202729 So it's unnecessary.
 
@user202729 and then?
 
Handle some sign changes and square both sides.
(I suppose? What's wrong?)
 
1:12 PM
but you need to golf it
 
You didn't say this is ! Anyway let's see...
 
what do you think CMC means :P
 
Chat Mini Challenge, of course.
Too many cases to consider... too bad.
 
2:14 PM
@LeakyNun Well the equality (a+b√2 = c+d√2) would only hold if a=c and b=d. That might be helpful for golfing (?)
 
@Mr.Xcoder I don't think it is helpful
 
Not sure either, hence the (?)
But it is interesting to solve without floats (which I know you have a profound hate for :P)
 
2:44 PM
Should I use the system as root user? [Linux]
 
3:22 PM
@PeterTaylor How can this be a duplicate?
BTW... does pinging the question/answer editor work?
 
3:46 PM
^^ That one has restriction on number of points can be used. If it is not restricted then it's indeed equivalent to find the convex hull.
So... anyone can reopen it?
 
 
1 hour later…
5:04 PM
@user202729 I agree with Peter Taylor. There is a difference but I don't see it as significant enough.
 
0
Q: How to solve this challenge?

reeeeeConsider the following challenge: Whilst looking in to a gang of hackers who were targetting satellites our agent came across a former rocket engineer who is now using his programming skills to hide secret codes. He wrote the below code which triggers a launch sequence but it needs activating. C...

 
I agree with Peter and WW too
 
0
A: Sandbox for Proposed Challenges

Jo KingSame Name, Lame! Write a function or program that, when given a list of names, outputs or returns a list where duplicates of given names have a unique shortened version of their surname. Input: A list of names, where a name is defined by a given name and a last name seperated by a space. Name...

 
5:43 PM
@JoKing @l4m2 Please don't answer off topic questions in comments.
 
@Christopher2EZ4RTZ I'm so happy I could help.
@LeakyNun is n√m the same as n×√m or ⁿ√m ?
 
@Adám the former
 
Unless the formatting is horrible
 
-4
Q: How to solve this challenge? (really hard!)

reeeeetry this: Well done on making it to the secret bonus challenge! Our agents have been struggling to deal with a hacker obsessed with clocks and timing. He set up an elaborate collection of pages with content that changes based on a timer. We've replicated it below, can you figure out how to get t...

 
Dang: 4 downvotes already
 
6:02 PM
Sorry @Dennis.
 
No worries, just something to keep in mind.
 
@Dennis Does it answer?
 
@l4m2 Whether it's a complete answer or not, aside from trying to make the challenge on topic or directing them to the proper SE site, we shouldn't help users with off topic questions.
2
 
Because if you answer (even partially) off-topic questions, you'll stimulate them to post more and more of them, and that isn't beneficial for this site.
 
6:19 PM
How do I chat not by replying?
 
@l4m2 don't chat?
 
@l4m2 With pings or what do you mean? Like this @<username here>? Example: @Mr.Xcoder?
 
6:44 PM
-1
Q: 2017 The year that was

Quantum spaghettificationSince we are coming to the end of another year I thought I would do a related challenge. Challenge The challenge is as follows: output: The year that was followed by a randomly select a word out of a list N>=5 . The words must satisfy the following conditions: All be English word in this...

 
 
1 hour later…
8:10 PM
CMC: Return a non-null pointer that is guaranteed to segfault upon being dereferenced
 
@EsolangingFruit I didn't find a solution, but I did discover that printf("%s", ""+1); prints %s, which I think is interesting.
 
Fun fact: Changing int to char in that program causes it to segfault
 
Does anyone have a suggestion on how to present math(s) in challenge wordings now that we have neither MathJax nor mathurl.com due to the requirement for https?
 
@trichoplax You can use ATaco's MathJax generator and then host the resulting image on imgur, if you're fine with the image being on its own line
 
@trichoplax codecogs!
 
8:22 PM
@EsolangingFruit Thanks. I can do that with mathurl.com as a last resort, but I wanted to check if there is another way first, as I need to edit at least one of my old challenges now that all the mathurl links no longer show correctly
 
1
Q: R[oman|everse] Polish Notation

Jesse Daniel MitchellIt is the year MDLXVII in a world in which the Roman Empire never fell, and the collapse into the dark ages never occurred. Due to the extended period of Pax Romana, the empire's economic stability enabled technology to progress at a rapid rate. The Romans have begun to dabble with circuitry, a...

 
@Pavel I made a quine in C using that type of logic
 
@Pavel Oh, I see - this works because both string literals are stored in a read-only data section, one after the other.
No idea why the compiler would put them in a different order, though...
 
Would love math integration, but KaTeX over MathJax, because it's a bit faster.
 
@ConorO'Brien Hah! That works! Thank you :). I copied the anchor text directly into a paragraph in my challenge and it displays perfectly, as it uses https. I have some editing to do...
Not sure how I feel about a full stop after a :)
 
8:29 PM
If I run file on /dev/pts/0, I get character special (136/0). /dev/random gives character special (1/8), and /dev/urandom gives character special (1/9). What do those numbers indicate?
Also, it seems that /dev/stdin, /dev/stdout, and /dev/stderr are all symlinks to files in /proc/self/fd/, which are themselves symlinks to /dev/pts/0, which is... only one file. And not three.
 
@EsolangingFruit Nice username, by the way
 
It's intended to be a pun on "Low-Hanging Fruit"
 
I got that :)
 
9:09 PM
@ATaco On your 12/12 entry about Funky "There are two naïve solutions to this" displays as "There are two naïve solutions to this" for some reason (I'm on Chrome 60.0.3112.78)
 
Have you tried switching it off and on again? Or using Firefox?
2
 
Someone isn't using good encodings!!
 
naïve encodings?
 
Anonymous
Sounds like WTF-8
8
 
Haha, Python has a module for everything :)
 
9:18 PM
@Mr.Xcoder like what?
 
@Zacharý A module for roman numerals, a module for xkcd, everything. And I love abusing them on PPCG
 
Yeah, but there not there by default.
That's what APL and Mathematica are for!
 
Umm, does APL really have that much built-ins?
 
dfns
Brainfuck, morse code, subways, lisp
 
the roman numeral module is in the standard library
 
9:21 PM
... No? Where?
 
There is one at least
I'll see if I can find it
it had a really obscure name
 
I use this one (not in the standard library)
 
I only use nltk, sympy, and numpy as external libraries. That's all I ever use, because it's all I'll ever need
external
Re is embedded in Python, no?
 
Ah yeah
 
I thought that the correct way is to use re2
Not that I do that
 
9:27 PM
@Zacharý Standard library yeah
 
>>> import formatter
>>> f = formatter.AbstractFormatter(None)
>>> f.format_roman(None, 12)
'xii'
 
That's to roman numerals
We need FROM roman numerals
 
@trichoplax Regarding using firefox: It's probably a good idea, but I'm on a school computer that won't let me run it. My only other option (if you could call it an option) is to use Windows.
 
@EsolangingFruit It wasn't meant too seriously. I do prefer Firefox, but I also like Chrome, and use it where speed is the priority (for example long running programs).
 
Chrome's devtools are kind of strange though
They generally work, but have some weird behavior sometimes
For example, attempting to view minified JS causes a lot of lag
Searching through all the sources (a feature which is strangely difficult to find) takes a very long time
 
9:32 PM
I also found the devtools in Chrome unintuitive. For my KotH I used Firefox for most of the debugging and optimisation, and Chrome to run the tournaments because it's faster
 
huh, I always switched to chrome from firefox for devtools
 
Interesting - did you use the profiler? I couldn't make sense of it
 
@trichoplax I haven't made sense of the profiler anywhere :p
 
And the format roman only goes up to 3999
 
@Zacharý Romans can only represent numbers up to 3999 because that is when their empire will finally fall
 
9:41 PM
_
v
You really are ESOTERIC, eh?
 
Someone hates modules :'( -1 on Conor's solution and mine
 
10:01 PM
..APL has built-in roman numeral math but that also outputs in roman numbers
huh my roman to decimal implementation in APL is only a byte longer than in SOGL
 
@dzaima To get decimal output: {}'III'{⎕←⍺+⍵}roman'IV'
 
3
Q: Could They Be The Same Day Of The Week?

Jonathan AllanChallenge Given a non-negative integer, output whether it is possible for two dates (of the Gregorian calendar) differing by exactly that many years to share a day of the week under the assumption that a year is a leap-year if it is divisible by four but not divisible by one-hundred and not four...

 
@Adám oh wow that's smart and cheaty
 
@dzaima I'll suggest to John Scholes to break out the utility functions which convert to and from, so they can be used separately too.
 

« first day (2527 days earlier)      last day (2315 days later) »