« first day (1987 days earlier)      last day (2846 days later) » 

7:02 AM
@NewMainPosts omg yes a challenge cheddar can participate in \o/
 
I'd do that, but I'm doing stacky logic
soon I will join that one
 
It seems like a fun one to golf
with JS I'm thinking, .split the string, .map across it to get the first letter? (map bc its less bytes)
@MᴀʀsUʟᴛᴏʀ I was planning on doing setInterval(n,1000); so you can see the cursor do its thing
 
I actually golfed off some bytes!
 
7:17 AM
@MᴀʀsUʟᴛᴏʀ if you haven't noticed I have no idea what I'm doing
but the fact that I was using jQuery is probably enough to know that
@DestructibleWatermelon nice! have you posted your answer yet?
 
no, still golfing a bit
 
0
Q: Programming Challenge - Gaming Console

tim3inA new type of computer game is launched in the market, which requires a special type of gaming console. Makers of the games has made a new generation gaming console with a very unique remote. The keys/Layout of remote is as shown below This remote contains 12 keys with 2 nonfunctional keys. Ea...

 
@DrGreenEggsandIronMan is it possible to pronounce that V answer
 
Yes. It's pronounced:
 
I'm gonna post my answer now
 
7:21 AM
Do you like the answer? I'll add an explanation soon.
 
318 bytes
posted it
 
0
A: Sandbox for Proposed Challenges

InsanePrint a Pilcrow Scarecrow Print the following ascii scarecrow using the pilcrow character ¶ ¶¶¶ ¶¶¶¶¶ ¶¶¶ ¶¶¶ ¶ ¶¶¶¶¶¶¶¶¶¶ ¶¶¶ ¶¶¶ ¶ ¶ ¶ ¶¶ ¶ ¶¶ ¶ ¶ ¶¶¶¶¶¶¶¶¶¶¶ Padding must be with (space) and built with ¶ Trailing padding is okay This is code-golf ...

 
@NewSandboxedPosts Disclaimer: I'm kind of baked
 
@DestructibleWatermelon your variable names are perfectly sane
it's code golf
General question: does anyone here use Mathematica and pay for it?
 
Is it only pay for?
I'm pretty sure martin uses it.
 
7:35 AM
@DrGreenEggsandIronMan Yes
 
There's a trial but I couldn't find a way to get it at a reasonable price
It seems really fun but I'm not going to use it without a massive discount
 
It's not that they are short.
 
haha lol
 
It's that they have nothing to do with what the variable has
except s is always input()
always
I don't know why, but it is
 
7:40 AM
@MᴀʀsUʟᴛᴏʀ 0/10 no jQuery
 
@charredgrass jQuery is overkill
 
@MᴀʀsUʟᴛᴏʀ your face is overkill
 
Plus, that's only for HTML input/output, not part of the solution
 
jkjk
@DestructibleWatermelon My code golf variables are probably worse. I've been playing with JS and learned I can use stuff like underscores and deltas as variables
 
Hi everyone!
 
7:43 AM
Further golfed + explanation:
2
A: Code golf to make logos for New Stack exchange sites

Dr Green Eggs and Iron ManV 31 29 bytes Óóüì ys$|ÄVr-r+$.YLpp$hrvÓÁ/ Note the trailing space at the end. Explanation: Óóüì This is a compressed regex. It removes everything except for digits and uppercase characters. ys$| "Surround this line with '|' characters. Ä "Duplicate this line...

I love simple ASCII-ART challenges cause they let me use my favorite language. :)
 
woah that compressed regex
 
hi all
 
I don't even want to know how that works
 
It's actually stupidly simple. Set the high bit of a character, and you get \<that character>
So \A Is just ASCII 'A' (e.g. 65) + 128
 
@DrGreenEggsandIronMan I hate simple ascii art because they remind me how bad my favorite language can be ^^
 
7:50 AM
Haha, what's your favorite language?
 
@DrGreenEggsandIronMan Lua
It has a minimalist core...
 
lua rocks!
 
No split function, no real regexes and some other flaws for golfing
 
@Katenkyo Oh, nice! I work with Lua!
 
@Lembik It does, but not in golfing contest :p. Otherwise, it's a wonderful language!
 
7:52 AM
I haven't actually had to learn it yet though...
 
how is luajit these days?
@Katenkyo also the guy is a genius
 
@DrGreenEggsandIronMan It's easy to learn as long as you know how C and functional languages works
@Lembik who?
 
OK. I know C, but I've never used a functional language.
 
@DrGreenEggsandIronMan Not even JavaScript? Oo
or php?
(well, php is less of functional, but still)
 
JS, no, PHP a tiny bit ages ago.
 
7:54 AM
@Katenkyo Mike Pall
 
These days I code exclusively in C and V. :)
 
@Lembik But he's a man who gets angry easily ^^
 
@Katenkyo some geniuses do :)
 
will I get lynched if I admit I code almost exclusively in JS
 
@DrGreenEggsandIronMan Does that help you with you resume (bad puns are best puns)
 
7:57 AM
@Katenkyo but try writing a JIT compiler on your own :)
@charredgrass yes!
 
@Katenkyo I think you mean procedural languages, when talking about C. Functional languages are languages like Lisp and Haskell
 
@charredgrass unless someone pays you to do that :)
 
@charredgrass No. There's a nearly 50/50 split of people who like JS and people who hate it.
 
@Sherlock9 That's why I spoke about C AND functional languages, as Lua is eavily based on how C works, but is a functional language by essence
 
Python's the same way, with the opposite people.
 
7:58 AM
do people actually like JS??
 
Yes!
 
@Lembik I will never be able to \o/
 
@DrGreenEggsandIronMan Hmm.. I am not sure I agree :)
 
@charredgrass We make fun of JS, but we're not burning the heretics :D
 
@Katenkyo nor can any normal person!
 
7:58 AM
PHP is more universally hated.
 
there is a great website called wtfjs but it seems to be down right now
 
@Katenkyo JS isn't functional, last I checked (isn't a functional programming language, I mean)
 
I'm a node.js guy though
 
@Sherlock9 lots of languages have snuck in functional features over the years
 
@Sherlock9 (I forgot how my definition of functional is wicked and should correct it)
 
7:59 AM
@Lembik But that's not to say that it's entirely a functional language
 
@Sherlock9 true.. but most functional programming languages also include non-functional parts these days too :)
 
Structured programming has many items from Lisp, but that's not to say that all languages that use structured programming are dialects of Lisp
Fair enough
 
@Lembik Most functional languages are Multi-Paradigm
 
@Katenkyo s/functional//
 
of course everyone should always do everything in Haskell :)
 
8:01 AM
@charredgrass That's probably fine :D
 
offering a bounty in 48 minutes.. but how large should it be?!
 
@Lembik Don't know whether to go "hear, hear!" or "har har"
 
@DrGreenEggsandIronMan sure, nowadays, you can easily do everything with anything
 
@Sherlock9 :)
 
@Lembik 5k rep
 
8:02 AM
@Lembik all your rep
 
@Katenkyo ?
@charredgrass I can't do that!
you only get a limited set of options
 
What's the bounty on?
 
@Lembik 10k rep? ^^
 
6
Q: Compute the maximum number of runs possible for as large a string as possible

Lembik[This question is a follow up to Compute the runs of a string ] Consider the following definitions taken from The number of runs in a string by W. Rytter. Note that word, string and substring are all roughly synonyms. |w| means the length of string wand w[i] refers to the ith element of string...

@Katenkyo isn't 500 the max?
 
@Lembik yes it is
 
8:03 AM
but I am not sure that works
 
You just have to find a way to hack into SE's back-end to change that
 
what I would like is to auction the rep :)
ok I'll do that :)
thanks for the upvote
 
oh woah since when did I get these privileges
 
@charredgrass which?
 
...all of them
I joined PPCG yesterday, lol
 
8:11 AM
I just saw your picture
I feel it needs some explanation :)
 
0
A: Sandbox for Proposed Challenges

FatalizeNormal Text Write a program or function which, given an input string and a standard deviation σ, outputs that string along the normal distribution curve with mean 0 and standard deviation σ. Normal distribution curve The y coordinate of each character c is: where σ is given as input, and wh...

 
There were a lot of challenges today! Like 5 of them all came in at once.
Alright, it's getting late. Good night everyone! And new users!
 
byee
 
@Fatalize That's a nice challenge
 
@Katenkyo thanks
I feel like I've done billions of those "write this string in this shape" challenges
 
8:18 AM
@DrGreenEggsandIronMan Hmm. Do you have the character space to spare to have both?
 
This, this, this, and now the one in the sandbox
 
@Fatalize Yes, but even if I still didn't do a challenge of this type, I like them (or at least, the concept :))
 
They're cool to look at
 
@Doorknob Theoretically yes. I have lots of characters still open. Although I was planning on mapping to :g and :g! so then I'd have to use four.
 
Anyone else just lose connection from StackExchange chat?
 
8:22 AM
Not me.
 
I lost it for like 10 mins and just reconnected, weird
Super weird since I still had connection to other SE sites
 
8:43 AM
so uh
whats goin on people
 
Clothes are going on people. Sometimes other people, too
 
bounty about to be added... that's it really
 
Commas are very important :P
 
and apostrophes :)
 
@Lembik what question are you putting a bounty on?
 
8:48 AM
45 mins ago, by Lembik
6
Q: Compute the maximum number of runs possible for as large a string as possible

Lembik[This question is a follow up to Compute the runs of a string ] Consider the following definitions taken from The number of runs in a string by W. Rytter. Note that word, string and substring are all roughly synonyms. |w| means the length of string wand w[i] refers to the ith element of string...

 
in 60 seconds
 
oh I was going to answer that challenge
but it was too difficult for my tiny JS mind
 
@charredgrass noo.. and now there is code to look at
in the comments
and a bounty
 
ok i did it here's my code bpaste.net/show/2aa056c1e9f9
jk
 
brilliant! How high did you get? :)
 
8:54 AM
uhhh magic
 
magic?
 
yes
I had to import magic
 
oh that
:)
 
Hello
 
9:02 AM
Helloooo
 
hi
 
-1
Q: Challenge: Find Combinations

tim3ingiven are the two array x[] and y[][] if x and y contains value as shown below where x[] contain key value. how can i find all possible combination of x[i] with y[i][j] by specifying pair level. for example if pair level is 2 then the combinations will be AA, AB, AD if pair level is 3 the...

 
any luck on the bounty yet @Lembik?
any answers
@NewMainPosts RIP
 
@NewMainPosts Again an Homework question
 
2 in a very short span of time
why do they even come to PPCG for homework lol
 
9:11 AM
@charredgrass By the same user with 2 different account
 
@charredgrass You can see close votes? o_O
 
No, I've just been sitting on the new posts
 
@zʏᴀʙiɴ101 No, 2 new homework challenges
 
@charredgrass nooooo
 
(boss left, have to stay at work until 6 to click a button at 6)
 
9:13 AM
@charredgrass I never had a strict scheduling of my work hour ^^
I come in between 8h and 8h30 and go out around 17/18h
 
I remember at one time, I discovered an alternate C preprocessor which used the % symbol... now I can't find it.
% instead of #
 
uhhh
#define % #
wait no that wont work
 
No it allowed more
Like actual loops
 
user214599
Oh you guys were talking about my challenge right
 
which one?
 
user214599
9:21 AM
Code golf to make logos for New Stack exchange sites
 
@MatthewRoh Yep, some times ago ^^
 
Oh yeah, I'm writing some JS for it right now
 
user214599
:)
 
user214599
+---+
 
/[A-Z\d]/ should work nicely
er
/([A-Z\d])/
 
9:22 AM
going to stop looking at ppcg for a bit in the hope that someone will answer while I am away :)
 
@MatthewRoh but the STDIN was too strong with this one, and we stopped talking about it
 
user214599
+----+
|T19B|
+----+
....v
 
+----+
|T19B|
+----+
    v
after you're done typing, just press ctrl+K and it will turn your message into a code block
 
cool
 
user214599
+----+
|T19B|
+----+
    v
 
user214599
9:24 AM
Like this?
 
i love this shortcut
 
9:37 AM
the best part about code golf in JS ES6 is that I don't need to tab out to test code I can just test it in whatever browser I have open
 
> Deprecated since version 3.3, will be removed in version 4.0.
Python 4.0 .___.
 
RIP
what function?
 
the u type code
 
@TùxCräftîñg In python 4.0 you'll be able to import darkMatter
 
we can already import antigravity...
 
9:40 AM
I know...
 
how to initialize a array.array with a specified size ?
 
@TùxCräftîñg which language?
 
python
 
Aren't the array dinamicaly sized in python?
(wow, this word looks so bad...)
 
yes but i want the array to be initialized with a specified size
 
9:44 AM
uhhhhh
you mean list?
 
I don't really get why you would want to do that or what's the use Oo
 
oh
I know
 
arrays are more memory efficient than lists
 
9:44 AM
so for a vm this is perfect
 
for
for loop and array.array.append(None) however many times you want!
Actually a possible partial solution depending on what you're doing
 
self.memory = array.array("B")
for i in range(memsize): self.memory.append(0)
look very bad from c#
 
user214599
uh huh
 
self.memory=array.array("B");for i in range(memsize):self.memory.append(0)
golf it for no reason
uhhh save memory
 
user214599
They r the saem
 
9:48 AM
@charredgrass python is compiled to bytecode then executed so the memory usage is the same
 
yes but what about the .py file on your computer? got to save those 3 bytes :P
 
user214599
uhh I dont think so
 
PPCG is a bad influence, I just witnessed myself golfing actual production code
and I debated not using the word "witnessed" there because it's too long
 
@charredgrass Hum, it won't usually save you any space as you don't have memory blocks of 1 byte ^^
 
oh
uhhh
readability then, it makes more stuff on the screen!
 
9:50 AM
@charredgrass One statement per line is judged more readable :)
 
sure maybe to normal people like you
 
How rude of you to call me "normal"
I am perfect, but for one flaws
 
finally get to go home
cya
 
I tend to underestimate myself
Oh, I have the codegolf badge!
 
what is the codegolf badge ?
 
user214599
9:56 AM
tag badge
 
@Katenkyo Gold badge? :D
 
@zʏᴀʙiɴ101 No, only bronze :)
 
I don't have any gold badge :)
I'm happy to see that some of my most upvoted codegolfs, are also the longest I've done ^^
 
\o/ a community ad
 
10:00 AM
@TùxCräftîñg Where?
 
in the main page of PPCG
 
Hello, and welcome @DestructibleWatermelon to Programming Puzzles & Code Golf chat ^^
 
so I had an idea for a challenge, right?
What it was: It was to find whether a positive int n had a prime number of divisors. A "metaprime" (everything is better with meta :)).
 
10:05 AM
Community ad idea: an ad to promote the esolang wiki
6
 
@Fatalize Then create it
 
But, i figured out what the actual sequence would be, and seems very much that the sequence is just the first squares, and between 1 and 100 the sequence ends
 
@Bálint Ain't got time nor talent for that
 
@Fatalize Because the other promotion ads are made by experts
 
open gimp
 
10:17 AM
remembered that i dont know how to draw a line
 
@TùxCräftîñg Use a tool, then shift
Or control/command
I just had a promotion text idea: "Want to beat everyone? Learn Jelly!"
 
sometimes 05AB1E beat Jelly
or do the same byte count
 
Also, there's already a strong impetus to learn golfing languages to "win". We don't necessarily need to encourage that.
 
The title pretty much says "freshly bought chocolate milk"
 
ツ but in what lang .__.
 
10:29 AM
@TùxCräftîñg Hungarian
@CᴏɴᴏʀO'Bʀɪᴇɴ JS is what it is because of multiple security reasons
With a low-level language it would be pretty unsecure to surf the web
 
low-level dont mean unsecure
 
@TùxCräftîñg Low-level means managing memory (almost)
And if you can manipulate memory, then you can do almost everything
 
due to the memory protection a ll language can only mess up the browser
 
@TùxCräftîñg Much better
 
I'm not sure if this is feasible or useful, but could one create a low-level dialect of Lisp?
 
10:43 AM
@Sherlock9 If you wrote a compiler from Lisp to Assembly, then that would be a low-level dialect of Lisp. I think this has already been done.
53
A: Are there Lisp native code compilers?

Rainer JoswigMany Lisp compilers compile to 'native' code. 'Native' means here 'machine code' (x86 in 32bit or 64bit mode, PowerPC, SPARC, ...). Other questions: can 'non-native code' compilers generate single file executables? -> Yes. can 'native code' compilers generate single file executables? -> Ye...

 
0
A: Sandbox for Proposed Challenges

milesCombination Sieves Given an integer n which represents the number of items in a list, generate all masks to select k items from n for k in [0, 1, ..., n], and group each selection of k items together. For example, if n = 4, for k in [0, 1, 2, 3, 4], [0, 0, 0, 0] k = 0 [0, 0, 0, 1] k = 1 [0,...

 
@Downgoat I really appreciate the fact that you said Pytek-like and not PHP-like... :P
 
@El'endiaStarman Cool :D Thanks for the link
Hm, I was thinking of how Paul Graham used Lisp in his web service (I think it got turned into Yahoo Shopping or something) and I was wondering if Lisp could be used in, say, games or factoring large numbers or other code that needs to be fast, and where C/C++ is usually used
 
11:01 AM
commit c2801cb6c72ca3bb9f51e295ff4e63ca3d3cbf7b
Author: zyabin101 <[redacted]>
Date:   Fri Jul 8 14:57:23 2016 +0400

    Initial commit

commit 4a1deda6d1c316086ec14d86f6263b4ced5ab7a4
Author: zyabin101 <[redacted]>
Date:   Fri Jul 8 10:56:09 2016 +0000

    Add new file
Crappiest resulting log after a crappy "initial commit" by GitLab and a non-successful git rebase --interactive.
How to squash commit 4a1deda6 into c2801cb6? >:|
 
^ you probably don't want to display your mail
or your name
@zʏᴀʙiɴ101
 
:3089234[13] I copied straight from the git log, non censored. And time to edit that is out.
 
well too bad
 
@zʏᴀʙiɴ101 Do you want me to edit it?
 
@El'endiaStarman Sure.
@El'endiaStarman Thanks.
Using squash on the first item of the rebase list is invalid (the squash lights red), and c2801cb is the only item in the rebase list.
So the only thing I can do is remove the commit from the rebase list, and let rebase have nothing to do.
That doesn't affect the log.
I need it to contain only one compound commit.
What should I do?
 
11:13 AM
ask SO
 
7a3f1adc4526a386f149d5a2bb110ec0e2b832a9 Initial commit
4a1deda6d1c316086ec14d86f6263b4ced5ab7a4 Add new file
Still two commits! :|
I used this answer:
382
A: Squash my last X commits together using Git

Mark LongairYou can use git merge --squash for this, which is slightly more elegant than git rebase -i. Suppose you're on master and you want to squash the last 12 commits into one. First check that git status is clean (since git reset --hard will throw away staged and unstaged changes) and then: # Reset ...

And still got two commits.
817356cda23674a7bb043ad378826b393f56b118 Initial commit
YISS~! I got it! \o/
88
A: Combine the first two commits of a Git repository?

kostmoUse git rebase -i --root as of Git version 1.7.12. In the interactive rebase file, change the second line of commit B to squash and leave the other lines at pick: pick f4202da A squash bea708e B pick a8c6abc C This will combine the two commits A and B to one commit AB. Found in this answer.

And now, I did this in a dev copy of the repo. Time to do it in prod.
remote: GitLab: You are not allowed to force push code to a protected branch on this project.
master is not protected.
Also, I'm the project owner, so I should be exempt from this pre-receive hook.
It's just GitLab just preventing me to write anything to this repository.
 
11:42 AM
hi again
 
user214599
Hi
 
After a long fuss with GitLab protected branches and Git squashing, I finally made a thing on GitLab.
 
i have a challenge idea
 
user214599
What is it?
 
@TùxCräftîñg I have a challenge idea review.
Please put up the idea.
 
11:52 AM
given a map, say if mario can go to the end
  =
  =
===
will return true because mario can jump over the wall
 
@El'endiaStarman Ah I forgot to ping you in my second reply chat.stackexchange.com/transcript/message/30892171#30892171
 
because mario can jump at 5 block of height max
 
this sounds familiar
Isn't that problem np-hard?
 

« first day (1987 days earlier)      last day (2846 days later) »