install pygame linux python3 code example Example: how to install pygame using pip in ubuntu sudo apt-get install python-pygame