how to create a square in pygame code example
Example: pygame how to draw square
#Importing the library
import pygame
# Initializing Pygame
pygame.init()
# Initializing screen
screen = pygame.display.set_mode((400,300))
# Initialing Color
color = (255,0,0)
# Drawing Rectangle
pygame.draw.rect(screen, color, pygame.Rect(30, 30, 60, 60))
pygame.display.flip()