����JFIF���������
1#@!#!123s
D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
usr
/
lib64
/
python3.8
/
turtledemo
/
__pycache__
/
Filename :
penrose.cpython-38.opt-1.pyc
back
Copy
U ����e5d3 ����������������������@���s����d�Z�ddlT�ddlmZmZ�ddlmZmZ�dZ dede�d���Z d d ��Zdd��Zd d��Z dd��Zd&dd�Zdd��Zdd��Zdd��Zdd��Zddeddfdd�Zefd d!�Zd"d#��Zed$kr�e��Ze���d%S�)'a��� xturtle-example-suite: xtx_kites_and_darts.py Constructs two aperiodic penrose-tilings, consisting of kites and darts, by the method of inflation in six steps. Starting points are the patterns "sun" consisting of five kites and "star" consisting of five darts. For more information see: http://en.wikipedia.org/wiki/Penrose_tiling ------------------------------------------- �����)�*)�cos�pi)�perf_counter�sleepgP�/7���?��������� ���c�����������������C���sT���t�|��}td��t|���td��t|��td��t|��td��t|���td��d�S�)N�$����l���������f�lt�fd�rt��l�fl��r����*/usr/lib64/python3.8/turtledemo/penrose.py�kite���s����r���c�����������������C���sT���t�|��}td��t|���td��t|��td��t|��td��t|���td��d�S�)Nr ���r���r ���r���r���r���r����dart%���s����r���c�����������������C���s����|dkrFt���\}}tt���t|d�t|d���}}}dt|||f<�d�S�t|��}td��t||d���t|���t d��t ||d���td��t|�t���t d��t ||d���td��t|���t d ��t||d���td��d�S�) Nr���r���Tr �������r���������������)�pos�int�heading�round�tiledictr���r����inflatedartr���r����inflatekite�d�r����nZpx�py�h�x�yr���r���r���r���r#���1���s(���� "r#���c�����������������C���s����|dkrFt���\}}tt���t|d�t|d���}}}dt|||f<�d�S�t|��}t||d���td��t|���t d��t ||d���td��t|�t���t d��t ||d���t|���t d ��d�S�) Nr���r���Fr���r ���r����6����~���r���)r���r���r���r ���r!���r���r#���r���r���r���r"���r$���r%���r���r���r���r"���G���s"���� "r"���c�����������������C���s����t����|�t|��}�t|�d�|�d�|��tD�]T}|\}}}t||��t|��t|�rftd��tdd��ntd��tdd��t���q*d�S�)Ng������Y@r����black)r�����������?r���r���)r.���r���r���) �clearr���Z shapesizer!���Zsetpos� setheading�shapeZcolorZstamp)r���r&����th�kr(���r)���r*���r���r���r����drawZ���s���� r4���c�����������������C���s$���t�d�D�]}t|�|��td��qd�S��N�����H���)�ranger#���r����r���r&����ir���r���r����sunj���s���� r;���c�����������������C���s$���t�d�D�]}t|�|��td��qd�S�r5���)r8���r"���r���r9���r���r���r����staro���s���� r<���c�������������������C���sT���t�d��t���td��t���tdt����t���td��t���tdt����t�d��d�S�)Nr����d���r���r���r���)�tracerZ begin_polyr���Zend_polyZregister_shapeZget_polyr���r���r���r���r���� makeshapest���s����r?���c�������������������C���s$���t����t���t���t���td��d�S�)N�user)�resetZhtZpur?���Z resizemoder���r���r���r����start����s ����rB������������)r���r���c�����������������C���sx���t�|��td��i�atd��||�|��t|�||��td��tdd��tD���}tdd��tD���}td||||�f���d�S�)Nr���r���c�����������������S���s���g�|�]}t�|�r|�qS�r����r!�����.0r)���r���r���r���� <listcomp>����s������ztest.<locals>.<listcomp>c�����������������S���s���g�|�]}t�|�s|�qS�r���rE���rF���r���r���r���rH�������s������z"%d kites and %d darts = %d pieces.)�gotor0���r!���r>���r4����len�print)r���r&����fun�startposr2���ZnkZndr���r���r����test����s���� rN���c�����������������C���sL���t����td�D�]8}t��}td||���t��}||�}|dk�rtd|���qd�S�)N����i,��r���)rB���r8����clockrN���r���)rL���r:����a�b�tr���r���r����demo����s����rT���c�������������������C���sj���t�d��tddd��tt��td��tt��td��tdd��tddd��td d dd��t d ddd��dS�)NZlogog333333�?r���r���r-���i8���gffffff�?r���zPlease wait...�center)zArial Blackr ���Zbold)ZalignZfontiX��rO���)�F����u���)rM���ZDone) �modeZbgcolorrT���r;���r���r<���ZpencolorrI����writerN���r���r���r���r����main����s���� ��rZ����__main__N)r���)�__doc__ZturtleZmathr���r����timer���rP���r���r���r$���r���r���r#���r"���r4���r;���r<���r?���rB���rN���rT���rZ����__name__�msgZmainloopr���r���r���r����<module>���s(���