Implement RAND and the turning ops.