import pygame screenx = 1280 screeny = 720 pygame.init() screen = pygame.display.set_mode((screenx,screeny)) clock = pygame.time.Clock() running = True #you better start running... while running: for event in pygame.event.get(): if event.type == pygame.QUIT: running = False screen.fill("black") pygame.display.flip() clock.tick(60) pygame.quit()