3

A time and space optimal stable population protocol solving exact majority