# define x, y and the amount of lines needed
x, y = 20, 20
lines = 49
# calculate the smallest step
colorStep = 1.00 / lines
# set stroke width
strokeWidth(10)
# start a loop
for i in range(lines):
    # set a cmyk color
    # the magenta value is calculated
    cmykStroke(0, i * colorStep, 1, 0)
    # draw a line
    line((x, y), (x, y + 960))
    # translate the canvas
    translate(20, 0)