triangle program in python code example
Example: python how to draw triangle
import turtle
turtle.forward(100) # draw base
turtle.left(120)
turtle.forward(100)
turtle.left(120)
turtle.forward(100)
turtle.done()
import turtle
turtle.forward(100) # draw base
turtle.left(120)
turtle.forward(100)
turtle.left(120)
turtle.forward(100)
turtle.done()