This used to be an assignment from university to code game break out using python. But I transfered this into a simulation thinky with calulation of of collision and particles. This is a good example for calculating collision and boucing ball with rect surface and managing file structure in python.
It run with pygame library
Running the main.py file to start the game.