Live data from Hacker News

Can you solve it? The Greplin programming challenge

challenge.greplin.com

21–30 of 167 posts

Re: Can you solve it? The Greplin programming challenge

#21
Wow the G. Address was horribly mutilated.

Four score and seven years ago our faathers brought forth on this containent a new nation conceived inz Liberty and dedicated to the proposition that all men are created equal Now we are engaged in a greaht civil war testing whether that naption or any nartion so conceived and so dedicated can long endure We are qmet on a great battlefiemld of tzhat war

Re: Can you solve it? The Greplin programming challenge

#22

Wow the G. Address was horribly mutilated. Four score and seven years ago our faathers brought forth on this containent a new nation conceived inz Liberty and dedicated to the proposition that all men are created equal Now we are engaged in a greaht civil war testing whether that naption or any nartion so conceived and so dedicated can long endure We are qmet on a great battlefiemld of tzhat war

This was intentional - we had to tie break the longest palindrome and we didn't want a quick diff to be able to see what we changed.

Re: Can you solve it? The Greplin programming challenge

#24
The last question isn't that difficult if you brute force it and have loads of memory. I tried to do it in python using itertools on my work thinclient and got a memoryerror. If you however break up your combinations.. you're good to go!

Fun, made my day. Good idea greplin dudes!

Re: Can you solve it? The Greplin programming challenge

#25
"Even if you're not looking for a job, we'd love to hear what you thought about the challenge."

I would be curious how many people did you lose because of phonecall requirement (before you changed it).

Also CSV for just a list of 22 numbers wasn't really necessary.

If you do web puzzle, the best is to keep everything self-contained, no downloads, no using external channels, just copy and paste.

FYI another Python cheater here (+Wolfram Alpha & Wikipedia, I'm lazy :).

Re: Can you solve it? The Greplin programming challenge

#26
post #25

"Even if you're not looking for a job, we'd love to hear what you thought about the challenge." I would be curious how many people did you lose because of phonecall requirement (before you changed it). Also CSV for just a list of 22 numbers wasn't really necessary. If you do web puzzle, the best is to keep everything self-contained, no downloads, no using external channels, just copy and paste. FYI another Python che…

I don't think trivializing the combinations with Python's builtins, looking up the fib primes with OEIS, or computing factors with Alpha is cheating. I hope, in fact, it's the whole point of the exercise: choose the right tools for the job. If you're writing code to test primeness or generate Fibonacci numbers, I sure as hell don't want to hire you.

Re: Can you solve it? The Greplin programming challenge

#27
I'm usually pretty bad at these kind of challenges (lately I tried registering at one mind-challenges site, but I couldn't even get past the five entry-level questions, which would have allowed me to even register), but this was surprisingly easy. Simple brute-force methods worked for each of the three tasks. I was totally surprised that the first time I entered the answer for each of the tasks, it was indeed the correct one.

But then again... these are all pretty standard computer science problems, nothing that I hadn't in some way done before.

On a side-note: Interestingly I used recursion for each of the three problems. Well... actually for the primes-problem I got stack overflow and rewrote it to not use recursion, but still, at least in principle :=)

Re: Can you solve it? The Greplin programming challenge

#28
Damn, I have to go in to work early today or I could continue this. The first one only took a minute or two of coding to solve in Perl. The search string was several times longer than my code, even with use warnings & use strict in there.

I'd write a bit of code to memoize the function before I'd do the Fibonacci numbers, though, and I just don't have time to continue right now, even though it's pretty easy. Are the rest of the tests like that? Do they force you to use more efficient code, rather than simpler brute force tests so that your code has a decent runtime?

Re: Can you solve it? The Greplin programming challenge

#29
post #26
post #25

"Even if you're not looking for a job, we'd love to hear what you thought about the challenge." I would be curious how many people did you lose because of phonecall requirement (before you changed it). Also CSV for just a list of 22 numbers wasn't really necessary. If you do web puzzle, the best is to keep everything self-contained, no downloads, no using external channels, just copy and paste. FYI another Python che…

I don't think trivializing the combinations with Python's builtins, looking up the fib primes with OEIS, or computing factors with Alpha is cheating. I hope, in fact, it's the whole point of the exercise: choose the right tools for the job. If you're writing code to test primeness or generate Fibonacci numbers, I sure as hell don't want to hire you.

Code to generate fibs is literally one line. Remember eigenvalues :)?

Re: Can you solve it? The Greplin programming challenge

#30

Anybody else browsing by mobile try to do Level 1 by inspection?

I was in the middle of thinking through the algorithm when I looked at it and saw the password in the text --- the password worked but I still want to code the algorithm later to confirm.
Post reply on HN