<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"
        integrity="sha384-GLhlTQ8iRABdZLl6O3oVMWSktQOp6b7In1Zl3/Jr59b6EGGoI1aFkw7cmDA6j6gD" crossorigin="anonymous">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.3.0/css/all.min.css"
        integrity="sha512-SzlrxWUlpfuzQ+pcUCosxcglQRNAq/DZjVsC0lE40xsADsfeQoEypE+enwcOiGjk/bSuGGKHEyjSoQ1zVisanQ=="
        crossorigin="anonymous" referrerpolicy="no-referrer" />
</head>
</html>
ó
Afc           @   so   d  Z  d d l m Z m Z d d l m Z d „  Z d „  Z d „  Z e	 d k rk e ƒ  Z
 e
 GHe ƒ  n  d S(	   s—        turtle-example-suite:

             tdemo_tree.py

Displays a 'breadth-first-tree' - in contrast
to the classical Logo tree drawing programs,
which use a depth-first-algorithm.

Uses:
(1) a tree-generator, where the drawing is
quasi the side-effect, whereas the generator
always yields None.
(2) Turtle-cloning: At each branching point
the current pen is cloned. So in the end
there are 1024 turtles.
iÿÿÿÿ(   t   Turtlet   mainloop(   t   clockc         c   s    | d k rœ g  } x[ |  D]S } | j  | ƒ | j ƒ  } | j | ƒ | j | ƒ | j | ƒ | j | ƒ q Wx) t | | | | | ƒ D] } d VqŠ Wn  d S(   s¤    plist is list of pens
    l is length of branch
    a is half of the angle between 2 branches
    f is factor by which branch is shortened
    from level to level.i   N(   t   forwardt   clonet   leftt   rightt   appendt   treet   None(   t   plistt   lt   at   ft   lstt   pt   qt   x(    (    s.   /usr/lib64/python2.7/Demo/turtle/tdemo_tree.pyR      s     c          C   s¯   t  ƒ  }  |  j d  ƒ |  j ƒ  |  j d ƒ |  j d d ƒ |  j d ƒ |  j ƒ  |  j d ƒ |  j	 ƒ  t
 |  g d d d ƒ } x | D] } qŠ Wt |  j ƒ  j ƒ  ƒ GHd  S(   Ni    i   iZ   i.ÿÿÿiÈ   iA   gffffffä?(   R    t   setundobufferR	   t
   hideturtlet   speedt   tracerR   t   penupR   t   pendownR   t   lent	   getscreent   turtles(   R   t   tR   (    (    s.   /usr/lib64/python2.7/Demo/turtle/tdemo_tree.pyt   maketree'   s    	


c          C   s%   t  ƒ  }  t ƒ  t  ƒ  } d | |  S(   Ns   done: %.2f sec.(   R   R   (   R   t   b(    (    s.   /usr/lib64/python2.7/Demo/turtle/tdemo_tree.pyt   main6   s    		t   __main__N(   t   __doc__t   turtleR    R   t   timeR   R   R   R   t   __name__t   msg(    (    (    s.   /usr/lib64/python2.7/Demo/turtle/tdemo_tree.pyt   <module>   s   				