ошибка в pygame Python
import pygame
import sys
def run():
pygame.init()
screen = pygame.display.set_mode(1200, 800)
pygame.dysplay.set_caption("Космические защитники")
bg_color = (0, 0, 0)
while True:
for event in pygame.event.get():
if event.type == pygame.QUIT:
sys.exit()
screen.fill(bg_color)
pygame.display.flip()
run()
ошибка:
Traceback (most recent call last):
File "D:\Python code\my 1 game.py", line 1, in <module>
import pygame
ModuleNotFoundError: No module named 'pygame'