I wrote this C++ code snippet a few months ago and it runs on a microcontroller inside SCR4P-E the "depressed and anxious robot". This code controls two DC motors that move the robot’s tracks and takes a random number to select which direction and speed the robot will do next - simulating chaotic pacing.