« first day (1897 days earlier)      last day (2937 days later) » 

11:00 AM
@MarsUltor Shows up as cout << "hello, world" << endl; for me.
Yup, this slogan thing is in a random language from the complex of the langs allowed in the code jam.
 
@Sherlock9 What do you mean?
 
> though we aren't certain that we'd recommend LOLCODE and Piet
^ Probably not an issue for some PPCG users
Next year, we need more esolangs in the GCJ qualifier
 
@KennyLau What do I mean by what?
 
@Sherlock9 The trial division thingy
 
Eh, I'll explain with actual code tomorrow
I don't want to go into too much detail while the competition is ongoing
 
11:07 AM
@Sherlock9 sure
 
they are offering prizes for toppest scoreboardleaders in hackerrank
 
But you don't have to find have to find every single jam coin in a range. Pick the low-hanging fruit. There's a lot of then
My mistake was trying to find the first 500 jam coins when any 500 would do
 
@KennyLau That's normal Erastothenes' sieve style if something is divisible by n, return n. (i.e. if something%n==0)
 
Oh that's what you're asking
 
@Sherlock9 my program is still running so you may not want to say that much
finding any 500 instead of the first 500 is out of my comfort zone xd
 
11:10 AM
AC 4:42:12
5 wrong tries
@MarsUltor Hilarious.
 
its freakin cool to walk past my neighbors with pe tshirt, more brilliant idea then receiving cash
 
@Agawa001 PE T-shirt?
 
@Sherlock9 5417
 
Trial division is dividing by a bunch of numbers to find factors, instead of some other algorithm
 
@zyabin101 yes project euler
 
11:11 AM
@KennyLau ?
 
@Sherlock9 thanks lol (yep i cheated)
 
not exe header of course
 
Well the last two hints I gave were just reminding you of the rules. Any 500
 
@Sherlock9 oh the time has expired. never mind
 
You can retry the small
Oh wait it's the big
Darn
 
11:12 AM
@KennyLau What's your Code Jam username?
 
kennylau
 
time is my main problem cant manage it accurately
 
Me neither
 
> Please remember that conversation about the problems during the round is prohibited.
Their Google+ page contradicts their rules
go-hero.net/jam/15/languages Disappointing, not enough esolangs
 
Ah, I shouldn't have discussed the problems
Sorry @KennyLau
 
11:17 AM
@MarsUltor which language has the lowest decay rate?
 
@Lembik Around equal, i think
 
@MarsUltor could be right.. haskell seems to do quite well from start to end
actually ocaml does better!
we need more idris solutions on ppcg!
 
Has anyone from PPCG gotten into the finals before?
 
@MarsUltor Erm, nope. No one... No.
 
> No contestant has ever achieved a perfect score in an onsite final.
 
11:25 AM
which finals ?
 
Code Jam
 
My solution to B was taking 18 seconds for the small dataset...
Then I realized I could enable optimizations
Now it's 3.6 seconds
 
@Doorknob But
So slow
There's an easier way
 
Yeah, but there's also brute force :D
 
Easier way is shorter and faster
 
11:40 AM
But there's also brute force :D
 
"Nope, easier way!" "Brute force!"
 
Cops have to be considerate of other sequences
0
A: Find the program that prints this integer sequence (Robbers' thread)

LegionMammal978Python 2, 87 bytes, Sp3000, A083054 n=input() _=int(3**.5*n)-3*int(n/3**.5)######################################## print _ Not that hard, actually. Just searched for sequences that met the constraints until I found one that could be generated in the given space.

 
Yeah, I know. I found a third one myself soon after, so I'm kicking myself right now for not looking for other sequences first
:/
 
You might want to update the cop answer
 
Was doing (and now done)
 
11:55 AM
What was your original program?
 
I don't really want to post that one in case I make another cop using similar ideas :/
(was hoping it'd be a fun one but clearly I've botched that pretty quickly)
 
There's a bit of a tradeoff when being a cop:
You can list common sequence elements, which risks other, possibly shorter programs meeting the constraints;
or you can list uncommon sequence elements, which risks the sequence being determined too quickly.
 
Yeah :/ I'm almost tempted to just list enough terms to uniquely identify the sequence, but somehow that'd be no fun I think
(or would it be fun? Not sure)
 
I can help you with that
For this challenge, I wrote a small C program that searches for sequences given some elements
@Dennis Just yesterday, in fact, I saw that for the first time in an actual website.
 
Hm...
 
12:03 PM
@KennyLau @MartinBüttner I wasn't the one who suggested disallowing no-ops (because its impossible to define a no-op). I did say that robbers should be allowed to use no-ops in their code
 
12:13 PM
@LegionMammal978 How did you find that sequence?
 
@KennyLau With my C program
$ ./seqfind _ _ _ _ 2 _ _ _ _ 2 _ _ _ _ 1 _ _ _ _ 1 _ _ _ _ 1
A007061 matches
A026465 matches
A030561 matches
A040959 matches
A048220 matches
A073783 matches
A083054 matches
A096993 matches
A097026 matches
A135265 matches
A152735 matches
A181810 matches
A233138 matches
A242081 matches
A242082 matches
A245920 matches
A245933 matches
A251092 matches
A253641 matches
A266640 matches
A266685 matches
 
@LegionMammal978 Ah, meta-golf.
 
Hm... okay, what happens if you add a(30) = 3?
 
$ ./seqfind _ _ _ _ 2 _ _ _ _ 2 _ _ _ _ 1 _ _ _ _ 1 _ _ _ _ 1 _ _ _ _ 3
$ ./seqfind _ _ _ _ _ 2 _ _ _ _ 2 _ _ _ _ 1 _ _ _ _ 1 _ _ _ _ 1 _ _ _ _ 3
A101312 matches
 
Good enough
 
12:16 PM
That is a nasty sequence haha
 
I'm reposting it, but to make it more fun you now have 3 less bytes
 
Yeah, sometimes you have to add another blank to account for offset 0 sequences
 
I'll post in a bit, but lemme see if I can golf this further first :P Feel free to think about how you would do that sequence in the template
 
@LegionMammal978 Is it closed source?
 
@zyabin101 Not at all
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

int main(int argc, char **argv) {
    char *num;
    char *seq;
    char line[1024];
    FILE *db;
    int match;
    int i;
    int j;
    db = fopen("Projects/Evolved/bin/Debug/db", "r");
    while (fgets(line, 1024, db) != NULL) {
        match = 1;
        seq = strtok(line, " ");
        for (i = 1; (num = strtok(NULL, ",")) != NULL && match && i < argc; i++) {
             if (*argv[i] == '_' || *num == '\0')
                 continue;
Although you'll have to find the OEIS sequence dump yourself ;)
I just reused it from my Evolution of OEIS sequence suggestion program
 
12:24 PM
k, posted. Have at it :)
 
@LegionMammal978 Not enough golfed.
low effort
 
@LuisMendo is not in this chatroom?
 
@LegionMammal978 But yeah, nice work with the searcher :) I wasn't sure whether to give the sequence away or not, but given the searcher it seems like difficulty via searchability won't cut it.
Can you add a keyword:nice to your search to narrow it down? (as an option, say)
 
No, the dump I have only contains the sequence elements themselves
formatted like:
 
12:29 PM
Ah, k
 
A269513 ,8,16,40,48,56,64,72,80,88,96,112,128,144,192,216,224,264,288,296,360,368,440,456,480,608,616,672,752,760,856,912,920,960,1128,1176,1216,1424,1432,1440,1464,1480,1552,1728,1872,
 
So it's not like it actually does networking to search, I guess
 
(in one line)
@Sp3000 Yeah, don't want to DoS their servers ;)
 
:P
 
oooh, I think I solved CodeJam D
 
12:33 PM
@NathanMerrill username?
 
@flawr Nice answer :)
 
I haven't done it yet, but NathanMerrill
 
hahaha
 
"Sorry, you can't have more than 30 friends at a time." >_<
 
irl?
 
12:36 PM
lol, no, in the code jam scoreboard
ok I removed somebody :p
 
initially I thought that the fact that G tiles simply get replaced with N gold tiles is irrelevant, but its the key to the who thing
 
@xsot How? I thought the judge on the small input only tests for the small input test cases?
 
xsot means, assuming your small and large use the same algorithm, you can test your algorithm so that if it works on small it probably also works on large
 
I did that for a problem, and although the algorithm is the same, the small solution crashed for some reason
I furiously recoded it in java and managed to confirm it within 8 minutes :p
 
@aditsu How did you find 30 people to befriend?
 
12:46 PM
that must be facebook
 
@MarsUltor irc and this room
(from previous years)
 
I like to call the cardinality of ℕ the "fixed point of the successor function" because that's what it is
 
oh and also a few friends irl (former colleagues)
 
My brain is going to explode from it being so dense for these hints
 
@Sp3000 Please remember that the sequence I found has an offset of 1901.
 
12:49 PM
Were we counting offsets? I was really confused about that
 
Yes
So you have to use 1905, 1910, etc.
 
:/
 
@Sp3000 That post is still valid; you just have to change the function inputs to match.
 
Yeah, but it changes the byte count :/
 
12:55 PM
\o/ Creating a code jam library, reduced a solution from 240 to 133 chars
 
@Sherlock9 ^ What Sp3000 said. This is more relevant for D in particular since it's not easy to verify the correctness of the output locally
 
@KennyLau On the phone. I'll be here later
 
I'll be gone
 
@Sp3000 The shortest I can do, though, is
from datetime import*;_=sum([int(date(n,a,13).weekday()==4)for a in range(1,12)])
 
Yeah, the point is to do it a lot shorter than that, but if the program needs to account for the offset then it's not as fun :/
 
1:05 PM
Except, of course, that my algorithm is having a hard time with medium inputs too and I'm getting really, really frustrated
I should not need itertools. I should not be checking every string K^C but I can't think of anything else!
 
@Sherlock9 I've actually found a formula that works
you should never need to iterate
the fact that G gets replaced with all G is key
 
@ChrisJester-Young Interesting. Thanks.
@ChrisJester-Young Huh, what does partition do?
I think I get how that one works but it seems a little strange.
 
1:24 PM
@LegionMammal978 Yeah, if it's okay I might keep it deleted sorry - the offset's part of the fun and I also just found this...
 
Actually I just realized the real proper way to do it would be to find a way to interweave the two lists together.
If I can take '(1 2 3) '(4 5 6) -> '(1 4 2 5 3 6) then I can just iterate through that instead of having to do this
 
looks at past Code Jam solutions
Wow, C++ is so verbose
 
@NathanMerrill I'd say I should sleep on it, but the contest ends 9 am tomorrow and I may very well sleep through the end
 
@EᴀsᴛᴇʀʟʏIʀᴋ ihaichu
 
And I want to get D, and all these hints: "there's a linear algorithm", "base K", "G gets replaced with all G" are not making it in >_<
 
1:26 PM
@Sherlock9 So
 
@CoolestVeto >.</
 
@Sherlock9 base 3 complexity 3 = 123123123123123123123123123, 111222333111222333111222333, 111111111222222222333333333
 
(so many spoilers :/)
 
@Sp3000 My bad
 
@xsot Nah it's fine. At least yours was more subtle :P
 
1:29 PM
G gets replaced with all G means g overrides l
@Sp3000 Don't look
 
Wait can you map in parallel
oh that's awesome
 
Doesn't matter to me now anyway, but I'll go, er, warn Martin
 
All I have to do is map cons over them and flatten
 
We may need to move this discussion though or drop it
 
And Dennis, Maltysen, Mego, Kenny and Chris
 
1:31 PM
@Sherlock9 The contest ends 5 am tomorrow here.
 
@Sp3000 wishes for >!
 
Hmm that wouldn't be too bad in chat, actually
 
>! spoiler
Yup, doesn't work.
 
@Sherlock9 Would checking the first K tiles work?
 
@NathanMerrill For small. And I think I just figured it out. I should try to figure it out myself in the next round :$
THough I have been trying
 
1:36 PM
er, that's not what I'm saying
would having the students check the first K tiles work?
every time
 
Oh
 
@Maltysen @Mego anyone who knows python/java please try to do some past problems if you want to. send a PR with your solution here
 
@NathanMerrill hey I found a file with user names, you used a different one last time :/
that may be another way I got to 30 friends :p
 
@aditsu yes, on a different email
 
in PPCG Minecraft Server, 12 secs ago, by CoolestVeto
I'm missing: 27 stacks of bread, 20 stacks of baked potatoes, 9 stacks of uncooked potatoes, 5 stacks of hay bales, 4 stacks of wheat, 8 stacks of coal, 18 stacks of beets, 9 stacks of carrots, and 6 stacks of seeds.
ಠ_ಠ
 
1:43 PM
I used the new email in case google is looking into my account (I have an interview on Wed)
 
ooh
 
1:55 PM
@MarsUltor You can download peoples' past solutions via the scoreboard
 
there's also go-hero.net/jam with all past solutions and statistics
 
2:24 PM
@ChrisJester-Young Why doesn't call-with-values seem to work with map? For example this doesn't work: (call-with-values (partition even? (range 1 5)) (lambda (x y) (map + x y)))
Throws an arity mismatch
 
Which people did join the code jam from the last time I asked? What are their usernames?
 
well, I'm aditsu
 
@aditsu Added. Are you in Romania?
 
no, I'm from Romania
 
@aditsu Okay.
@Doorknob what is your code jam username?
Is it right that Doorknob's code jam username is KeyboardFire?
RSMFTD
in Sandbox, 1 hour ago, by RedRiderX
> foo extra bar
ಠ_ಠ

extra foo
> ಠ_ಠ
 
2:46 PM
do any of you guys know some simple electronics?
 
How simple is simple?
 
like simple enough to answer this
 
@trichoplax Simple.
 
am I right in saying that the effectine resistance of a capacitor is 1/f?
where f= frequency
 
How does one use the 05AB1E TIO?
 
2:48 PM
I don't think it is dependent only on f
 
joy
I'm trying to write up how a resistor and a capacitor behave whilst in parallel with varying frequencies
 
thanks?
 
Does it help?
 
@zyabin101 yeah
 
2:51 PM
just checking now
 
You're dealing with AC, right?
 
@trichoplax All Clear?
 
Alternating Current
 
@LegionMammal978 What do you mean?
 
@Adnan It doesn't seem to be accepting input.
 
2:53 PM
yay
java crashed my browser!
 
Hmm, can you give an example?
 
My program is LŸæO, don't see anything wrong with it
 
@LegionMammal978 Give it as command line arguments.
 
@zyabin101 no
 
@zyabin101 Then it still doesn't output anything
 
2:54 PM
@Adnan Then IDK ¯\_(ಠ͜ ಠ)_/¯
@LegionMammal978 ^
 
O only works on lists containing ints. You can use the debug flag though
You are really close :p
 
@Adnan Found it, just had to flatten
 
@muddyfish If you want more than just my wikipedia based answers, you could try Electrical Engineering
 
Nice, great job :)
 
Wait no it still outputs 0 in input 1
 
2:57 PM
Oh
 
LŸæ`O should be working...
 
@muddyfish Apart from the omega times C factor, the result is imaginary, so it's impedance (reactance), not resistance. You need to deal with complex numbers in order to "mix" capacitors and resistors
 
Oh, flatten also acts as union facepalm
 
@LegionMammal978 Hmm, ` is just a flatten operator, not deep flatten :p
And I messed up the font again
 
@Adnan Well, the list is only two levels deep
Like [[1, 2, 3], [4, 5, 6]]
 
2:59 PM
This new cops n' robbers challenge is so much fun :D
 
Yes, so what remains is [1, 2, 3], [4, 5, 6] and that is the stack
 

« first day (1897 days earlier)      last day (2937 days later) »