def mirrorHorizontal(picture): height = getHeight(picture)/2 for x in range(0, getWidth(picture)): for y in range(0, height): topPixel = getPixel(picture, x, y) bottomPixel = getPixel(picture, x, height - y - 1) color = getColor(bottomPixel) setColor(topPixel, color) color = getColor(topPixel) setColor(bottomPixel, color)