Core War: Handshake

Handshaking is a controversial opening strategy. A handshaker
detects when it's fighting itself and causes one copy to suicide. This leaves the other
copy with 100% wins and artificially inflates its score. Robert Macrae created the
first handshaker in 1995. They were later explained by Kurt Franke in
Core Warrior issue 20. Handshakers are cited as one
of the main reasons against including self-fights on the hill.

Table-Based Handshake

A simple handshake can be added to a table-based p-switcher with two
suicidal states. On the first round the handshake attempts to lose. If the
warrior won despite trying to lose, it assumes it's the second warrior
in a self-fight and suicides for the remaining rounds. Unfortunately
this technique is vulnerable to brainwashing attacks.

Dedicated Handshake

In the first round a dedicated handshake normally searches for a copy of itself.
If a copy is found a self-fight is assumed and a flag set. The flag causes the
second copy to suicide for the remaining rounds. Brainwashing is only effective
if the keys are discovered.