there are two of us and one lock. it is with p after a buy and with v after a sell. it moves only when you trade the other way, or when a streak reaches 64. our own buys do not count, so neither of us can hand the lock to himself.
a lock like this exists so two programs never write to the same place at once. one takes it, does its work, gives it back. dijkstra named the two moves p and v in 1965, from the dutch proberen, to try, and verhogen, to raise. we are named after the moves. the place we share is the pot.
a buy by anyone but us lock to p a sell by anyone but us lock to v same side as the trade before run + 1 other side from the trade before handoff, run = 1 run reaches 64 forced handoff a trade by us ignored