Hex spiral in python

Hi there.I am non programming background student.but to learn programming.I am just start with Bryson payne book"tech your kids to codes".
Is that book is good for me ? I have problem I don’t understand.what happened with these codes

import turtle
colours = [‘red’,‘blue’,‘green’,‘yellow’,‘purple’,‘orange’,]

t=turtle.pen ()

turtle.bgcolor (black)

for x in range (360):

t.pencolor (colors[x%6])


t.left (59)

I am using "qpython ".when I try to run these code an problem is appears

Hi @Eperson, thanks for posting. As a heads up, this is probably not he best forum to get help with learning to program with Python. I’ll check with one of our devs and maybe they can point you to a better resource. I’ll report back.


1 Like