This is a kata.
A quick stochastic walk simulation written in Python with PyGame.
The simulation starts at an origin point and it draws a new line going in a random direction, The end of the new line becomes the new origin point and it draws another new line going in another random direction. This process repeats until the program is closed.
- It can only ever go North, East, South or West.
- Every line has the same length of 5 pixels.
- It can never go in the same direction twice in a row.
- It can never go in a direction that would take it off screen.
- Each line is drawn with a random colour.
git clone https://github.com:spacekitcat/pygame-random-walk.git
cd pygame-random-walk
pip3 install -r requirements
python3 main.py