# What makes a sequence an interesting golf challenge?

We have lots of challenges tagged . What types of sequences make for interesting golf challenges? How can we assess whether a given sequence is worth writing a challenge about?

I understand that we need both easy and difficult challenges (for people with different ability levels in their chosen language(s), and for people with different amounts of free time), so this won't just be about that.

What factors are there to take into consideration when writing a sequence golf challenge?

• I think the most important consideration is how interesting/useful the properties of the sequence are to math at large. Primes are awesome. Negative integers are boring.
– user45941
Feb 9 '16 at 20:44
• @Mego I hadn't thought of considering how interesting the sequences are in themselves. I was thinking more of which ones would be an interesting challenge to golf. I wonder if both of these factors affect people's enjoyment and inclination to compete. Feb 9 '16 at 20:47
• @Mego I would probably be a little careful with primes, though; they're a bit overdone. They're kind of like the "Hello, World!" of sequences.
– Doorknob Mod
Feb 9 '16 at 20:48
• I would think so. The properties of the sequences (like the Bernoulli numbers, which have multiple ways of formulating the sequence, and are closely related to trigonometry and the Riemann zeta function) is the thing that interests me the most.
– user45941
Feb 9 '16 at 20:49
• @Doorknob I'm not proposing we have more challenges about primes. I'm simply stating that the sequence of prime numbers is a very interesting one.
– user45941
Feb 9 '16 at 20:49
• @Mego Interesting. I guess sequences with multiple formulations give a variety of approaches to golfing too, which may even vary between languages. Feb 9 '16 at 20:50

# Number of approaches

I often see that questions which have multiple ways of being solved are more interesting than challenges which have only one exact way to approach the problem. If that's the case, it is just a contest of who has the best built-ins. When there are multiple approaches, it's also quite a puzzle of finding out which approach is better for your submission.

## Make sure there's no trivial closed form solution

This is probably a corollary of Adnan's answer, but even with sequences that have many definitions and approaches there is often a simple closed form solution that a) completely sidesteps the interesting background of a sequence and b) is the only viable golfing option. Always try to make sure that closed form solutions are either hard to come up with or sufficiently complicated that they don't dominate the challenge (e.g. by checking the Formula section on OEIS).

• An example of this is the Fibonacci sequence. (phi^n - (1-phi)^n)/sqrt(5) is much simpler and often shorter than the iterative or recursive computation methods (floating-point nonsense aside).
– user45941
Feb 9 '16 at 21:03
• @Mego Floating point nonsense is probably why that's actually a bad example for most languages. A better example is this one. Feb 10 '16 at 10:13

# Simple to understand, but not trivial

This probably applies to all challenges. I found this out after posting some -challenges, but the easier it is to understand the challenge, the more interested people are. If you come up with a very difficult challenge which require a lot of mathematical knowledge, people are less likely to submit an answer.

Also important, don't make it too easy. Trivial challenges are not encouraged to be posted, and would probably lead to 3-byte answers, etc.