title: Pygame Erasing Images on Backgrounds
body: <p>You blit an image onto your surface to use as your background. Then you press button X to blit an image on the same surface, how do you erase the image? I have this so far, but then I end up with a white rectangle in the middle of my background.</p>
  
  <pre><code>screen = pygame.display.set_mode(1280, 512)
  
  screen.blit(background, (0,0))
  
  while True:   
      pygame.display.flip() #flip is same as update
      for event in pygame.event.get():
          if (event.type == pygame.KEYDOWN):        
              if event.key == pygame.K_SPACE:
                  screen.blit(player, (x, y))
              if event.key == pygame.K_BACKSPACE:
                  pygame.draw.rect(screen, [255,255,255], (x, y, 62,62))
  </code></pre>