Pygame, as its name shows, is an open-source multimedia library in Python mainly used to make video games that include graphics, sounds, visuals, etc. These days, game programming is quite successful.
It is a cross-platform library that will work on multiple platforms with a single code-base. This library contains a lot of modules for graphics and sounds, as any game is meaningless without sounds or graphics.
Install Pygame in Python 2.7
To use this library, we should install it first. If you are running Python
2.7 version, you should use the following command to install Pygame.
conda install -c cogsci pygame
After entering this command, the terminal asks to proceed with installing the packages; press
Y to proceed. The packages will install in a short amount of time.
To check whether Pygame is successfully installed or not, you can use the following command.
If you found the Pygame in the list, it means it is successfully installed.