Server IP : 162.213.251.212 / Your IP : 3.141.18.167 [ Web Server : LiteSpeed System : Linux business55.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64 User : allssztx ( 535) PHP Version : 8.1.31 Disable Function : NONE Domains : 1 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /lib64/python3.6/encodings/__pycache__/ |
Upload File : |
3 \� � @ s� d Z ddlZdd� Zdd� Zdd� Zd d � Zdd� Zd Zdd� Zdd� Z dd� Z dd� Zdd� Zdd� Z dd� ZG dd� dej�ZG dd� dej�ZG d d!� d!ej�ZG d"d#� d#eej�ZG d$d%� d%eej�Zd&d'� ZdS )(uY Codec for the Punicode encoding, as specified in RFC 3492 Written by Martin v. Löwis. � Nc C sT t � }t� }x2| D ]*}t|�dk r2|jt|�� q|j|� qW t|�}t|�|fS )z 3.1 Basic code point segregation� )� bytearray�set�ord�append�add�sorted�bytes)�str�base�extended�c� r �*/usr/lib64/python3.6/encodings/punycode.py� segregate s r c C s* d}x | D ]}t |�|k r |d7 }q W |S )z@Return the length of str, considering only characters below max.r � )r )r �max�resr r r r � selective_len s r c C sR t | �}xD|d7 }||krdS | | }||kr:|d |fS ||k r |d7 }q W dS )a Return a pair (index, pos), indicating the next occurrence of char in str. index is the position of the character considering only ordinals up to and including char, and pos is the position in the full string. index/pos is the starting position in the full string.r N���r )r r )�len)r �char�index�pos�lr r r r �selective_find s r c C s� d}g }d}x~|D ]v}d }}t |�}t| |�} | d || } xBt| |||�\}}|dkr^P | || 7 } |j| d � |}d} qBW |}qW |S )z3.2 Insertion unsort codingr r r r r r )r r r r )r r Zoldchar�resultZoldindexr r r r Zcurlen�deltar r r �insertion_unsort0 s$ r c C s, d| d | }|dk rdS |dkr(dS |S )N�$ r � r )�j�biasr r r r �TF s r# s$ abcdefghijklmnopqrstuvwxyz0123456789c C sr t � }d}xbt||�}| |k r4|jt| � t|�S |jt|| | d| � | | d| } |d7 }qW dS )z(3.3 Generalized variable-length integersr r r N)r r# r �digitsr )�Nr"