# Rules for Duels

### TL;DR

What rules and guidelines should duels and duelers be held to?

This idea sprouted originally as a potential solution to this problem. It was well received so the next step is to create formal rules and to address foreseeable complications.

### What is Dueling?

A duel is an arranged engagement in combat between two individuals with matched weapons in accordance with agreed-upon rules. Used to gain "satisfaction", that is, to restore/defend one's honor.

In this context, it would be a duel between two golfers. There is a challenger, who throws down the gauntlet and there is the champion who accepts the challenge.

### How it works

• Challenger
• the question
• his language
• his opponent's language
• time frame
• rep
• Champion
• chooses to accept the challenge
• Outcome
• after the time frame
• based on the question's winning criterion
• the better of the two answers wins
• the victor receives a bounty for the rep amount from the defeated

[Alternative] a Sponsor can post a duel that is open for two Champions. In this case, the rep is paid by the Sponsor to the victor.

### Next steps

If there is positive feedback, I will create a 'List of Duels', similar to our 'List of Bounties'. Challengers can post duels, champions can comment their acceptance, spectators can follow the links and assist.

Challenger

# Java vs C

I challenge anyone to out-perform Java with C in building a fewest-moves freecell solver.

Champion

### Example 2

I will sponsor 2 champions to create an auto-golfer for Batch

• Challenge: Auto BATCH Golfer
• Champion's Language: JavaScript
• Duration: 1 week
• Reputation: 500

Champion 1

Champion 2

I will fight for JavaScript

• This is interesting. I originally thought that Duels were a new challenge type, but its a rather interesting way for people to participate in existing challenges. – Nathan Merrill May 16 '17 at 15:42
• Is there any reasonable way to mitigate the challenger's benefit to be able to work on the challenge for as long as they want (before posting the duel and until a champion accepts). – Martin Ender May 16 '17 at 16:46
• You also have a similar problem with champions working on the problem before accepting. – Nathan Merrill May 16 '17 at 16:49
• I guess the simplest solution is to make the time frame long enough that time is not an issue. – Martin Ender May 16 '17 at 17:13
• What if you have a tie? – Christopher May 16 '17 at 22:00
• @MartinEnder There's also bias in that the challenger can come up with a problem of a kind they are good at, or already has ideas on how to golf. I think the best solution is to have a third-party pose the challenge. – xnor May 17 '17 at 1:18
• @xnor Well if the person accepts they have already known what it is. So it doesn't matter. – Christopher May 17 '17 at 9:59
• The only problem I see with this is that one who proposes a duel could spend an arbitrary amount of time golfing their answer, giving him an unfair advantage – Conor O'Brien May 21 '17 at 1:37
• @ConorO'Brien It is something that champions will have to consider when browsing the duels. To mitigate this, challengers could post duels for recent questions or (per Martin's idea) they could make the duration long enough for champions to feel comfortable with whatever head start there might have been. – NonlinearFruit May 21 '17 at 3:34

# Draws

If the time frame for a duel elapses and either:

• Both solutions tie in terms of the winning criterion
• Neither dueler was able to create a solution

Then the duel resolves with no winner (no bounty is given).

# Duels may be sponsored by a user, who does not want to compete, for another user

A user who does not want to compete may sponsor a user and supply the rep if they lose. If a user challenges another user, but the challenged user cannot put the rep forward, then a kind user can step up and supply the rep if they lose.

• Could you elaborate on how this would work? A sponsor would post a challenge and wait for 2 champions to step forward? – NonlinearFruit May 16 '17 at 16:00
• @NonlinearFruit I was thinking a user challenges another user but the challenged user cannot put the rep forward. A kind user steps up and tells the challenged user that they will supply the rep if they lose – Christopher May 16 '17 at 16:02
• If the sponsored user wins, does the sponsor or the duelist get the rep? I guess that's something that the sponsor and duelist would decide. – Mego May 16 '17 at 16:02
• @Mego yeah sounds good – Christopher May 16 '17 at 16:05
• As it stands right now, you don't challenge specific users. When a challenger posts a duel, any champion is able to accept it. – NonlinearFruit May 16 '17 at 16:05
• @Mego it doesn't really make sense for the sponsor to get the rep since bounties are given for answers not for users. – Martin Ender May 16 '17 at 17:14
• @MartinEnder Sure, but logically you'd expect the sponsor to get the rep since they put up the bounty if their duelist loses. – Mego May 16 '17 at 17:14
• @MartinEnder they could split it. – Christopher May 16 '17 at 20:28
• Actually they probably can't split it. The site-enforced rules about how bounties work are quite complicated but amounts are fixed and bountying the same question more than once requires the second bounty to be for more than the first bounty unless the first one was already the maximum 500. – Peter Taylor May 16 '17 at 21:53
• @PeterTaylor different questions I guess. I don't know – Christopher May 16 '17 at 22:00
• @Mego (cc Christopher) my point isn't whether it makes sense to give some or all of the bounty to the sponsor, but that it's borderline abuse of the rep system. Bounties should be given to valuable answers that are worth drawing attention to, not to users. It's fine if someone wants to sponsor someone else with the bounty because it doesn't matter whose rep is given, but they shouldn't expect to get rep in return without being responsible for writing the answer that earned the bounty. If you're not comfortable putting your rep on the line without a chance to earn some, don't sponsor someone. – Martin Ender May 17 '17 at 6:11
• @MartinEnder That makes sense. I would just get people to duel Dennis over and over (or you :P) for 500 rep and would get super rep. – Christopher May 17 '17 at 9:58
• Challenging specific users isn't an ability that champions have. If a sponsor wants to sponsor a duel between two particular languages and on a particular question, then they should post the duel and state that 2 champions are needed and that the winner will receive the bounty from the sponsor. If a sponsor want to sponsor a particular champion, they should discuss it in chat and then both comment on the duel. – NonlinearFruit May 24 '17 at 17:12

# Time Frame

We need to be precise in terms of when the challenge completes.

• The challenger should specify a positive integer, x, number of days (e.g. 3).
• Time starts counting down at 12:01 am UTC once the champion accepts.
• Time ends at 11:59 pm UTC on the xth day.

### Example

1. A challenge with a 7 day duration is posted. A champion accepts the challenge on March 14th at 2:14 pm UTC.
• This duration will start decreasing on March 15th at 12:01 am UTC
• The challenge will complete on March 21st at 11:59 pm UTC
2. A challenge with a 1 day duration is posted. A champion accepts the challenge on October 31st at 11:30 pm UTC.
• This duration will start decreasing on November 1st at 12:01 am UTC
• The challenge will complete on November 1st at 11:59 pm UTC
• I am in a duel with WheatWizard and we have very simple rules. We both started with the same language same challenge at the same time and we both go until we finish. You do not need a end date – Christopher May 16 '17 at 22:01
• @Christopher If there's a bounty reward, when would you the bounty be awarded if there is no deadline? – Martin Ender May 17 '17 at 6:08
• @MartinEnder when you both finish. Not every duel needs to be formal was my point – Christopher May 17 '17 at 9:57
• @Christopher I don't believe we are considering informal duels here. If it is going through the formal process, it is a formal duel. – NonlinearFruit May 24 '17 at 16:53

# No Intra-language Dueling

Intra-language duels would be more sticky.

• Ties would be more likely
• Copying could be a problem
• Spectator involvement could become more political
• e.g. Why comment on her answer and not mine?

With reputation on the line, people could get bent out of shape on details like that. I also think that the competitors would be more inclined to give each other suggestions and be helpful in an inter-language duel. So overall formal intra-language dueling should not be permitted.

Obviously off-the-books intra-language dueling between friends is fine. Some of this already exists.

• I don't agree with this. These challenges are on an accept-basis, so if both parties agree to deal with these problems, let them. – Nathan Merrill May 16 '17 at 15:55
• A way to solve most of these problems would be for the competitors to post hashes of their solutions as comments on the duel post and only reveal the matching code after the deadline. Whether or not byte counts are disclosed could be decided by the challenger. – Martin Ender May 16 '17 at 16:44