content
stringlengths 7
1.05M
|
|---|
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# JTSK-350112
# complex.py
# Shun-Lung Chang
# sh.chang@jacobs-university.de
class Complex(object):
def __init__(self, real, imag):
self._real = real
self._imag = imag
def __add__(self, other):
if type(self) != type(other):
raise raiseTypeError('Type of {0} is not same as Type of {1}'.format(type(self),
type(other)))
return Complex(self._real + other._real, self._imag + other._imag)
def __sub__(self, other):
if type(self) != type(other):
raise raiseTypeError('Type of {0} is not same as Type of {1}'.format(type(self),
type(other)))
return Complex(self._real - other._real, self._imag - other._imag)
def __mul__(self, other):
if type(self) != type(other):
raise raiseTypeError('Type of {0} is not same as Type of {1}'.format(type(self),
type(other)))
return Complex(self._real * other._real - self._imag * other._imag,
self._real * other._imag + other._real * other._real)
def __truediv__(self, other):
if type(self) != type(other):
raise raiseTypeError('Type of {0} is not same as Type of {1}'.format(type(self),
type(other)))
return Complex((self._real * other._real + self._imag * other._imag) /
(other._real ** 2 + other._imag ** 2),
(self._imag * other._real - self._real * other._imag) /
(other._real ** 2 + other._imag ** 2))
def __str__(self):
return "Real Part: {0:.2f}\nImaginary Part: {1:.2f}".format(self._real, self._imag)
|
def gc_genome_skew(dna):
gc_skew=[]
gc_diff=0
for i in range(len(dna)):
gc_skew.append(gc_diff)
if dna[i]=='C':
gc_diff-=1
if dna[i]=='G':
gc_diff+=1
oric_list=[]
min_value = min(gc_skew)
for i in range(len(gc_skew)):
if(gc_skew[i]==min_value):
oric_list.append(i)
return oric_list
def main():
with open('datasets/rosalind_ba1f.txt') as input_file:
dna = input_file.read().strip()
oric_list = gc_genome_skew(dna)
print(' '.join(list(map(str, oric_list))))
with open('solutions/rosalind_ba1f.txt', 'w') as output_file:
output_file.write(' '.join(list(map(str, oric_list))))
if(__name__=='__main__'):
main()
|
#Operaciones:
print ("Ejercicio 1: Operaciones numéricas")
dividendo = 7
divisor = 3
#Si queremos obtener el resto de una dvisión empleamos el símbolo %. ej:
restoDivisión = dividendo % divisor
print (restoDivisión)
#Si queremos obtener el conciente, entonces empleamos la barra
cociente = dividendo / divisor
print (cociente)
#Sin embargo, si queremos el cociente como número entero ( como es en este caso donde la división no es exacta)
#empleamos una doble barra:
cocienteEntero = dividendo // divisor
print (cocienteEntero)
#Del mismo modo, si queremos multiplicar dos números emplearemos el asterisco
producto = dividendo * divisor
print (producto)
#Por l contrario, si lo que queremos es conseguir el resultado de la potencia emplearemos un doble asterisco:
potencia = dividendo**divisor
print (potencia)
#Las operaciones, al igual que matemáticas, cuentan con un ordn de prevalecencia
# También podeos hacer operaciones con cadenas de caracteres
print ("Ejercicio 2: Operaciones con caracteres")
ejemplo1 = "mama" + "papa"
print (ejemplo1)
ejemplo2 = "mama"*5
print (ejemplo2)
#Como se puede ver, concatena
#Importante a tener en cuenta que las variables no son igualdades, sino asignaciones
# ```así,
# si x = 3
# x = x + 1
# el valor final que tomará x es su valor más la unidad.
print ("Ejercicio 3: Cambio de variables")
#Ahora queremos crear un programa que intercambie el valor de 2 variables a y b
a = 3
b = 4
print ("el valor de a es", a)
print("el valor de b es",b)
#COmo es lógico, lo primero que se nos ocurriría es lo siguiente ´
# a = b
# b = a
# pero el error es lógico, si primero a toma el antiguo valor de b y luego b toma el valor de a2, entonces le estaremos asignando a a y b eñ mismo valor, el valor de b1.
# por lo tanto, la solución está en guardar el valor de a en una nueva variable (previamente), así:
a = 3
b = 4
print ("Valores iniciales")
print ("el valor de a es", a)
print("el valor de b es",b)
a2 = a
a = b
b = a2
print ("Valores tras el intercambio")
print ("el valor de a es", a)
print("el valor de b es",b)
|
ext = ('zero', 'um', 'dois', 'três', 'quatro', 'cinco', 'seis', 'sete', 'oito', 'nove', 'dez',
'onze', 'doze', 'treze', 'quatorze', 'quinze', 'dezesseis', 'dezessete', 'dezoito', 'dezenove', 'vinte')
val = int(input('Digite um valor:'))
while not 0 <= val <= 20:
val = int(input('Digite um valor:'))
print(f'o valor digitado foi {ext[val]}')
|
# Python 3.x
class AgeException(Exception):
def __init__(self, msg, age):
super().__init__(msg)
self.age = age
class TooYoungException(AgeException):
def __init__(self, msg, age):
super().__init__(msg, age)
class TooOldException(AgeException):
def __init__(self, msg, age):
super().__init__(msg, age)
# Hàm kiểm tra tuổi, nó có thể ném ra ngoại lệ.
def checkAge(age):
if (age < 18):
# Nếu tuổi nhỏ hơn 18, một ngoại lệ sẽ bị ném ra.
# Hàm sẽ bị kết thúc tại đây.
raise TooYoungException("Age " + str(age) + " too young", age)
elif (age > 40):
# Nếu tuổi lớn hơn 40, một ngoại lệ sẽ bị ném ra
# Hàm sẽ bị kết thúc tại đây.
raise TooOldException("Age " + str(age) + " too old", age);
# Nếu tuổi nằm trong khoảng 18-40.
# Đoạn code này sẽ được thực thi.
print("Age " + str(age) + " OK!");
|
""" 该代码仅为演示函数签名所用,并不能实际运行
"""
save_info = { # 保存的信息
"iter_num": iter_num, # 迭代步数
"optimizer": optimizer.state_dict(), # 优化器的状态字典
"model": model.state_dict(), # 模型的状态字典
}
# 保存信息
torch.save(save_info, save_path)
# 载入信息
save_info = torch.load(save_path)
optimizer.load_state_dict(save_info["optimizer"])
model.load_state_dict(sae_info["model"])
|
"""
Script to show sample use of ipf_api_client and nagios_api_client
"""
"""
export IPF_URL=""
export IPF_TOKEN=""
d=IPFDevice('L66EXR1')
d.hostname
d.ipaddr
export NAGIOS_URL=""
export NAGIOS_TOKEN=""
n=NAGIOSClient()
n.host_list()
n.hostgroup_list()
n.create_hostgroup("site")
s=NAGIOSHost(name=d.hostname,ipaddr=d.ipaddr,site=d.site)
s.delete()
"""
|
# Definition for singly-linked list.
# class ListNode:
# def __init__(self, val=0, next=None):
# self.val = val
# self.next = next
class Solution:
def insertionSortList(self, head: ListNode) -> ListNode:
if not head:
return head
dummy=ListNode(float(-inf)) #首项负无穷保证插的数据不在最前头
dummy.next=head #用于返回答案
pre=head
nxt=head.next
while nxt: #最后一项为None结束循环
if nxt.val>pre.val: #从头开始,如果后一项大于前一项不改变节点
pre=nxt #这两行移动指针(往后挪一格)
nxt=nxt.next
else: #如果后项小需要把后项nxt的节点插到正确位置
pre.next=nxt.next #把nxt指向的节点拿出来
cp1=dummy #这两个指针负责从头开始比较nxt的位置
cp2=dummy.next #使用dummy的原因见11行注释
while nxt.val>cp2.val: #因为前面是排好序的循环结束nxt正好在cp1和cp2中间
cp1=cp2 #
cp2=cp2.next #
nxt.next=cp2 #这两行负责插
cp1.next=nxt #把nxt指向的节点查到cp1和cp2中间
nxt=pre.next #指针从哪来回哪去 准备下一个循环
return dummy.next
|
"""
This module contains the templates for different search
requests (conjunction, data products, ephemeris)
"""
CONJUNCTION_SEARCH_TEMPLATE = {
"start": "2020-01-01T00:00:00",
"end": "2020-01-01T23:59:59",
"ground": [
{
"programs": [
"string"
],
"platforms": [
"string"
],
"instrument_types": [
"string"
],
"ephemeris_metadata_filters": {
"logical_operator": "AND",
"expressions": [
{
"key": "string",
"operator": "=",
"values": [
"string"
]
}
]
}
}
],
"space": [
{
"programs": [
"string"
],
"platforms": [
"string"
],
"instrument_types": [
"string"
],
"hemisphere": [
"northern"
],
"ephemeris_metadata_filters": {
"logical_operator": "AND",
"expressions": [
{
"key": "string",
"operator": "=",
"values": [
"string"
]
}
]
}
}
],
"events": [
{
"programs": [
"string"
],
"platforms": [
"string"
],
"instrument_types": [
"string"
],
"ephemeris_metadata_filters": {
"logical_operator": "AND",
"expressions": [
{
"key": "string",
"operator": "=",
"values": [
"string"
]
}
]
}
}
],
"conjunction_types": [
"nbtrace"
],
"max_distances": {
"ground1-space1": 300,
"ground2-space1": 400,
"ground1-events1": 900,
"space1-space2": None
}
}
DATA_PRODUCTS_SEARCH_TEMPLATE = {
"start": "2020-01-01T00:00:00",
"end": "2020-01-01T23:59:59",
"data_sources": {
"programs": [
"string"
],
"platforms": [
"string"
],
"instrument_types": [
"string"
],
"data_product_metadata_filters": {
"logical_operator": "AND",
"expressions": [
{
"key": "string",
"operator": "=",
"values": [
"string"
]
}
]
}
},
"data_product_type_filters": [
"keogram"
]
}
EPHEMERIS_SEARCH_TEMPLATE = {
"start": "2020-01-01T00:00:00",
"end": "2020-01-01T23:59:59",
"data_sources": {
"programs": [
"string"
],
"platforms": [
"string"
],
"instrument_types": [
"string"
],
"ephemeris_metadata_filters": {
"logical_operator": "AND",
"expressions": [
{
"key": "string",
"operator": "=",
"values": [
"string"
]
}
]
}
},
}
|
fibonacci_cache= {}
def fibonacci(n):
# If we have cached the value, then return it
if n in fibonacci_cache:
return fibonacci_cache[n]
# Compute the Nth term
if n == 1:
value = 1
elif n == 2:
value = 1
elif n >2:
value = fibonacci(n-1) + fibonacci(n-2)
#Cache the value and return it
fibonacci_cache[n] = value
return value
for n in range(1,101):
print(n, ":", fibonacci(n))
|
x = [0.0, 3.0, 5.0, 2.5, 3.7] #an array is a list of numbers
print(type(x))
#removing the third element
x.pop(2) #it pops off the (index)
print(x)
#removes the 2.5 element
x.remove(2.5)
print(x)
#add an element to the end
x.append(1.2)
print(x)
#get a copy
y = x.copy() #produces a 'deep' copy of x in memory (so it doesn't change the value of the variable)
print(y)
#how many elements are 0.0
print(y.count(0.0))
#print the index with value 3.7
print(y.index(3.7))
#sort the list (increasing numerical order)
y[0] = 5.9 #adds 5.9 in the beginning of the list
print(y)
y.sort()
print(y)
#reverse sort (decreasing numerical order)
y.reverse()
print(y)
#remove all elements
y.clear()
print(y)
|
def imc(a,p):
return p / (a**2)
peso = float(input("Digite seu peso: "))
altura = float(input("Digite sua altura: "))
imc = imc(altura, peso)
if(imc < 17):
print("Muito abaixo do peso\n")
elif(imc >= 17 and imc <= 18.49):
print("Abaixo do peso\n")
elif(imc >= 18.5 and imc < 25):
print("Peso normal\n")
elif(imc >= 25 and imc <30):
print("Acima do peso\n")
elif(imc >= 30 and imc < 35):
print("Obesidade I\n")
elif(imc >= 35 and imc < 40):
print("Obesidade II\n")
else:
print("Obesidade III\n")
|
# DO NOT EDIT -- GENERATED BY CMake -- Change the CMakeLists.txt file if needed
bigtable_client_unit_tests = [
"admin_client_test.cc",
"app_profile_config_test.cc",
"bigtable_version_test.cc",
"cell_test.cc",
"client_options_test.cc",
"cluster_config_test.cc",
"column_family_test.cc",
"completion_queue_test.cc",
"data_client_test.cc",
"filters_test.cc",
"force_sanitizer_failures_test.cc",
"grpc_error_test.cc",
"idempotent_mutation_policy_test.cc",
"instance_admin_client_test.cc",
"instance_admin_test.cc",
"instance_config_test.cc",
"instance_update_config_test.cc",
"internal/async_check_consistency_test.cc",
"internal/async_future_from_callback_test.cc",
"internal/async_longrunning_op_test.cc",
"internal/async_poll_op_test.cc",
"internal/async_retry_op_test.cc",
"internal/async_retry_unary_rpc_and_poll_test.cc",
"internal/bulk_mutator_test.cc",
"internal/table_async_check_and_mutate_row_test.cc",
"internal/instance_admin_test.cc",
"internal/grpc_error_delegate_test.cc",
"internal/prefix_range_end_test.cc",
"internal/table_admin_test.cc",
"internal/table_async_apply_test.cc",
"internal/table_async_bulk_apply_test.cc",
"internal/table_async_sample_row_keys_test.cc",
"internal/table_test.cc",
"mutations_test.cc",
"table_admin_test.cc",
"table_apply_test.cc",
"table_bulk_apply_test.cc",
"table_check_and_mutate_row_test.cc",
"table_config_test.cc",
"table_readrow_test.cc",
"table_readrows_test.cc",
"table_sample_row_keys_test.cc",
"table_test.cc",
"table_readmodifywriterow_test.cc",
"read_modify_write_rule_test.cc",
"row_reader_test.cc",
"row_test.cc",
"row_range_test.cc",
"row_set_test.cc",
"rpc_backoff_policy_test.cc",
"metadata_update_policy_test.cc",
"rpc_retry_policy_test.cc",
"polling_policy_test.cc",
]
|
# Assign functions to a variable
def add(a, b):
return a + b
plus = add
value = plus(1, 2)
print(value) # 3
# Lambda
value = (lambda a, b: a + b)(1, 2)
print(value) # 3
addition = lambda a, b: a + b
value = addition(1, 2)
print(value) # 3
authors = [
'Octavia Butler',
'Isaac Asimov',
'Neal Stephenson',
'Margaret Atwood',
'Usula K Le Guin',
'Ray Bradbury'
]
sorted_authors_by_name_length = sorted(authors, key=len)
print(sorted_authors_by_name_length)
sorted_authors_by_last_name = sorted(authors, key=lambda name: name.split()[-1])
print(sorted_authors_by_last_name)
|
# my_script
print(f"My __name__ is: {__name__}")
def i_am_main():
print("I'm main!")
def i_am_imported():
print("I'm iported!")
if __name__ == "__main__":
i_am_main()
else:
i_am_imported()
|
#!/usr/bin/env python
'''
* Author : Hutter Valentin
* Date : 08.05.2019
* Description : Hector agent monitoring
* Help : ANSI color from https://stackoverflow.com/questions/287871/how-to-print-colored-text-in-terminal-in-python
'''
class colors:
HEADER = '\033[95m'
BLUE = '\033[94m'
CBLUE = '\33[34m'
GREEN = '\033[92m'
ORANGE = '\033[93m'
RED = '\033[91m'
NORMAL = '\033[0m'
|
"""
Definition of TreeNode:
class TreeNode:
def __init__(self, val):
self.val = val
self.left, self.right = None, None
"""
class Solution:
"""
@param root: the given BST
@param k: the given k
@return: the kth smallest element in BST
"""
def kthSmallest(self, root, k):
self.idx = 0
return self.inorderTraverse(root, k)
def inorderTraverse(self, root, k):
if root is None:
return None
left = self.inorderTraverse(root.left, k)
if left is not None:
return left
self.idx += 1
if self.idx == k:
return root.val
return self.inorderTraverse(root.right, k)
|
n = input('digite algum : ')
print('o tipo primitivo desse valor e :',type(n))
print('isso e um numero ?',n.isnumeric())
print('isso e uma letra ?',n.isalpha())
print('isso e espaço ?',n.isspace())
print('isso e numero e letra ?',n.isalnum())
print('estar em maiusculas ?',n.isupper())
print('estar em minusculas ?',n.islower())
print('estar capitalizada ?',n.istitle())
|
"""
SpectralFlux.py
Compute the spectral flux between consecutive spectra
This technique can be for onset detection
rectify - only return positive values
Ported from https://github.com/jsawruk/pymir: 30 August 2017
"""
def spectralFlux(spectra, rectify=False):
spectral_flux = []
# Compute flux for zeroth spectrum
flux = 0
for nth_bin in spectra[0]:
flux = flux + abs(nth_bin)
spectral_flux.append(flux)
# Compute flux for subsequent spectra
for s in range(1, len(spectra)):
prev_spectrum = spectra[s - 1]
spectrum = spectra[s]
flux = 0
for mth_bin in range(0, len(spectrum)):
diff = abs(spectrum[mth_bin]) - abs(prev_spectrum[mth_bin])
# If rectify is specified, only return positive values
if rectify and diff < 0:
diff = 0
flux = flux + diff
spectral_flux.append(flux)
return spectral_flux
|
print("analise estatistico de grupos")
somaid =0
feminino =0
masculino =0
while True:
print("_"*20)
idade = int(input("Informe sua idade:"))
sexo = str(input("informe seu sexo:[M/F]")).upper()
print("-"*20)
if idade >= 18:
somaid = somaid + 1
if sexo == "M":
masculino = masculino +1
elif sexo != "F":
print("opcao invalida!")
if idade >=20 and sexo =='F':
feminino = feminino +1
while True:
resp = str(input("deseja informar novamente?")).upper()
if resp == 'S' or resp == 'N':
break
elif resp != 'N' and resp != 'S':
print("opcao invalida")
if resp == 'N':
break
print("="*10)
print(f"Dados impressos:\n{somaid} maiores de idade \n{masculino} do sexo masculino no gruupo\n{feminino} mulheres com 20 anos ou mais")
print("="*10)
|
def test_get_symbols(xtb_client):
symbols = list(xtb_client.get_all_symbols())
assert len(symbols) > 0
def test_get_balance(xtb_client):
balance = xtb_client.get_balance()
assert balance.get('balance') is not None
def test_ping(xtb_client):
response = xtb_client.ping()
assert response
|
# user.py
class User:
"""
Class representing an user.
Parameters
----------
TODO
Attributes
----------
Methods
-------
"""
def __init__(self, name, uuid=None):
self.name = name
self.uuid = self._get_uuid(uuid)
def _get_uuid(self, uuid):
"""
Get or create universally-unique identifier for user.
A UUID is generated only when the user is first created; otherwise,
this function returns the existing UUID.
"""
if uuid is None:
# TODO : create UUID function
pass
return uuid
# exercise statistics DB table
# date uuid ex_type_id ex_values user_solution actual_solution is_correct ex_time ex_level ex_subject ex_concepts user_mastery
|
class AgregationController:
def __init__(self):
"""
"""
def subscribe(self, url):
"""
:param url: URL
:return: boolean
"""
def notify(self, message, id):
"""
:param message: Message
:param id: List<TgUID>
:return: void
"""
|
def PagesInfo():
pagename = {
"page": "",
"page_code": "",
"label1": "名称",
"label2": "",
"label3": "",
"label4": "",
"label5": "",
"label6": "",
"label7": "",
"label8": "",
"label9": "",
"label10": "",
"qrcodelist": "",
"tableheight": "260",
"code1": "name",
"code1width": "80",
"code2": "code2",
"code2width": "80",
"code3": "code3",
"code3width": "80",
"code4": "code4",
"code4width": "80",
"code5": "code5",
"code5width": "80",
"code6": "code6",
"code6width": "80",
"code7": "code7",
"code7width": "80",
"code8": "code8",
"code8width": "80",
"code9": "code9",
"code9width": "80",
"code10": "code10",
"code10width": "80"
}
return pagename
|
#Solution code for exercise 1
#We make a loop to make the element by element product of two lists, we then compare to numpy
def list_product(list1,list2):
new_list=list1
if(len(list1)==len(list2)):
try:
for i,row in enumerate(list1):
for j,el in enumerate(row):
new_list[i][j]=list1[i][j]*list2[i][j]
except:
print('Both arrays should have the same dimensions')
return new_list
|
#Verificar si un numero es cuadrado
#sin usar metodo sqrt
def findSqrt (num):
l=0
r=num-1
while l<=r:
mid = l+(r-l)//2
if mid*mid == num:
return True
if mid*mid < num:
l=mid+1
if mid*mid > num:
r=mid-1
return False
print(findSqrt(14))
|
def iob_ranges(words, tags):
"""
IOB -> Ranges
"""
assert len(words) == len(tags)
ranges = []
def check_if_closing_range():
if i == len(tags) - 1 or tags[i + 1].split('_')[0] == 'O':
ranges.append({
'entity': ''.join(words[begin: i + 1]),
'type': temp_type,
'start': begin,
'end': i
})
for i, tag in enumerate(tags):
if tag.split('_')[0] == 'O':
pass
elif tag.split('_')[0] == 'B':
begin = i
temp_type = tag.split('_')[1]
check_if_closing_range()
elif tag.split('_')[0] == 'I':
check_if_closing_range()
return ranges
|
##创建自定义类
class Person:
def set_name(self,name):
self.name=name;
def get_name(self):
return self.name
def say_hello(self):
print("hello"+self.name);
def to_str(self):
print(self.name())
person=Person();
person.set_name("lily")
print(str(person));
##属性函数与方法
##函数与方法的区别:方法位于类里,有self参数,函数与类同级无self参数
class Mobile:
def set_os(self,os):
self.os=os;
def set_brand(self,brand):
self.brand=brand;
def get_os(self):
return self.os;
def get_brand(self):
return self.brand
def method(self):
print("I have a mobile"+self.os)
def fuction():
print("I dont have a Mobile")
sumsung=Mobile();
sumsung.set_os("Android")
sumsung.set_brand("Sumsung")
print(sumsung.method())
print(fuction())
##隐藏 如果想让方法或者属性成为私有,那么只需要让方法或者属性的名称以两个下划线开头即可,只可以在类中进行调用,
##在类外的作用域是调用不到的
class Pc:
def __brand(self):
print("this is my pc")
def print(self):
print("the pc is")
self.__brand()
mypc=Pc();
mypc.print()
# mypc._brand()
##指定超类
class Human:
def body(self,body):
self.body=body
def get_body(self):
print("humanbeing all have body")
def face(self,face):
self.face=face
def get_face(self):
print("humanbeing all have face")
class Man(Human):#指定human为man的父类
def dick(self,dick):
self.dick=dick;
def _get_dick(self):
print("man all have a dick or its a monster");
jackChan=Man();
jackChan.dick("big")
jackChan.body("strong")
jackChan.face("handsome")
print(jackChan.get_face(),jackChan.get_body(),jackChan._get_dick())
##判断一个类是否是另一个类的子类 使用 issubclass
print(issubclass(Man,Human))
##如果你有一个类想知道他的基类 那么使用_bases_方法
print(Man.__bases__)
##要确定对象是否是某个类的实例使用isinstance
print(isinstance(jackChan,Man))
##获得当前对象属于哪个类
print(jackChan.__class__)
##多继承暂时不考虑 太麻烦了
class boy(Man):
ages=14;
def set_age(self,age):
self.age=age;
def get_age(self):
print("im"+self.age+"old boy");
jim=boy();
jim.ages=14;
jim.set_age("14")
print(boy.__bases__);
attrs=getattr(jackChan,"dick");
print(attrs)
body_attr=hasattr(jackChan,"body")
print(body_attr)
##将对象的指定属性设置为指定的值
setattr(jackChan,"dick","tiny")
print(getattr(jackChan,"dick"))
##返回对象的类型
print(type(jackChan))
###接口与内省
##getattr(object,name[,default]) 获取属性的值 还可以提供默认值
|
# Вася делает тест по математике: вычисляет значение функций в различных точках.
# Стоит отличная погода, и друзья зовут Васю гулять.
# Но мальчик решил сначала закончить тест и только после этого идти к друзьям.
# К сожалению, Вася пока не умеет программировать. Зато вы умеете.
# Помогите Васе написать код функции, вычисляющей y = ax2 + bx + c.
# Напишите программу, которая будет по коэффициентам a, b, c и числу x выводить значение функции в точке x.
# -8 -5 -2 7
def get_func_result(a, x, b, c ):
return a*(x**2) + b*x + c
def read_input():
return [int(item) for item in input().split()]
if __name__ == "__main__":
a, x, b, c = read_input()
result = get_func_result(a, x, b, c)
print(result)
|
"""
Task
Given an integer, n, perform the following conditional actions:
If n is odd, print Weird
If n is even and in the inclusive range of 2 to 5, print Not Weird
If n is even and in the inclusive range of 6 to 20, print Weird
If n is even and greater than 20, print Not Weird
Input Format
A single line containing a positive integer, n.
Constraints
Output Format
Print Weird if the number is weird; otherwise, print Not Weird.
"""
if __name__ == '__main__':
n = int(input().strip())
if (n%2 == 1) or (n >=6 and n <= 20):
print("Weird")
elif (n >=2 and n <=5) or n > 20:
print("Not Weird")
|
# Definition for a binary tree node.
# class TreeNode:
# def __init__(self, x):
# self.val = x
# self.left = None
# self.right = None
class Solution:
def isValidBST(self, root: TreeNode) -> bool:
self.prev = None
def valid(node):
if node:
if not valid(node.left):
return False
if self.prev and self.prev.val >= node.val:
return False
self.prev = node
return valid(node.right)
else:
return True
return valid(root)
|
class Solution:
def lengthOfLastWord(self, s: str) -> int:
s = s.strip()
wordList = s.split(' ')
try:
lastWord = wordList[-1]
return len(lastWord)
except IndexError:
return 0
sol = Solution()
print(sol.lengthOfLastWord("hello world"))
|
valid_statues = ['active', 'inactive']
class ServiceIdentities:
def __init__(self, britive):
self.britive = britive
self.base_url = f'{self.britive.base_url}/users'
def list(self, filter_expression: str = None) -> list:
"""
Provide an optionally filtered list of all service identities.
:param filter_expression: filter list of users based on name, status, or role. The supported operators
are 'eq' and 'co'. Example: 'name co "Smith"'
:return: List of service identity records
"""
params = {
'type': 'ServiceIdentity',
'page': 0,
'size': 100
}
if filter_expression:
params['filter'] = filter_expression
return self.britive.get(self.base_url, params)
def get(self, service_identity_id: str) -> dict:
"""
Provide details of the given service_identity.
:param service_identity_id: The ID of the service identity.
:return: Details of the specified user.
"""
params = {
'type': 'ServiceIdentity'
}
return self.britive.get(f'{self.base_url}/{service_identity_id}', params=params)
def get_by_name(self, name: str) -> list:
"""
Return service identities whose name field contains `name`.
:param name: The name (or part of the name) of the service identity you wish to get
:return: Details of the specified service identities. If no service identity is found will return an empty list.
"""
service_identities = self.list(filter_expression=f'name co "{name}"')
return service_identities
def get_by_status(self, status: str) -> list:
"""
Return a list of service identities filtered to `status`.
:param status: valid values are `active` and `inactive`
:return:
"""
if status not in valid_statues:
raise ValueError(f'status {status} not allowed.')
return self.list(filter_expression=f'status eq "{status}"')
def search(self, search_string: str) -> list:
"""
Search all user fields for the given `search_string` and returns
a list of matched service identities.
:param search_string:
:return: List of user records
"""
params = {
'type': 'ServiceIdentity',
'page': 0,
'size': 100,
'searchText': search_string
}
return self.britive.get(self.base_url, params)
def create(self, **kwargs) -> dict:
"""
Create a new service identity.
:param kwargs: Valid fields are...
name - required
description
status - valid values are active, inactive - if omitted will default to active
:return: Details of the newly created user.
"""
required_fields = ['name']
kwargs['type'] = 'ServiceIdentity'
if 'status' not in kwargs.keys():
kwargs['status'] = 'active'
if kwargs['status'] not in valid_statues:
raise ValueError(f'invalid status {kwargs["status"]}')
if not all(x in kwargs.keys() for x in required_fields):
raise ValueError('Not all required keyword arguments were provided.')
response = self.britive.post(self.base_url, json=kwargs)
return response
# TODO - check this once a bug fix has been deployed
def update(self, service_identity_id: str, **kwargs) -> dict:
"""
Update the specified attributes of the provided service identity.
Acceptable attributes are `name` and `description`.
:param service_identity_id: The ID of the service identity to update
:param kwargs: The attributes to update for the service identity
:return: A dict containing the newly updated service identity details
"""
if 'name' not in kwargs.keys():
existing = self.get(service_identity_id)
kwargs['name'] = existing['name']
# add some required elements to the kwargs passed in by the caller
kwargs['type'] = 'ServiceIdentity'
kwargs['roleName'] = ''
self.britive.patch(f'{self.base_url}/{service_identity_id}', json=kwargs)
# return the updated service identity record
return self.get(service_identity_id)
def delete(self, service_identity_id: str) -> None:
"""
Delete a service identity.
:param service_identity_id: The ID of the service identity to delete
:return: None
"""
self.britive.delete(f'{self.base_url}/{service_identity_id}')
def enable(self, service_identity_id: str = None, service_identity_ids: list = None) -> object:
"""
Enable the given service identities.
You can pass in both `service_identity_id` for a single user and `service_identity_ids` to enable multiple
service identities in one call. If both `service_identity_id` and `service_identity_ids` are provided they
will be merged together into one list.
:param service_identity_id: The ID of the user you wish to enable.
:param service_identity_ids: A list of user IDs that you wish to enable.
:return: if `service_identity_ids` is set will return a list of user records, else returns a user dict
"""
computed_identities = []
if service_identity_ids:
computed_identities += service_identity_ids
if service_identity_id:
computed_identities.append(service_identity_id)
# de-dup
computed_identities = list(set(computed_identities))
response = self.britive.post(f'{self.base_url}/enabled-statuses', json=computed_identities)
if not service_identity_ids:
return response[0]
return response
def disable(self, service_identity_id: str = None, service_identity_ids: list = None) -> object:
"""
Disable the given service identities.
You can pass in both `service_identity_id` for a single service identity and `service_identity_ids` to disable
multiple service identitie at in one call. If both `service_identity_id` and `service_identity_ids` are
provided they will be merged together into one list.
:param service_identity_id: The ID of the user you wish to disable.
:param service_identity_ids: A list of user IDs that you wish to disable.
:return: if `user_ids` is set will return a list of user records, else returns a user dict
"""
computed_identities = []
if service_identity_ids:
computed_identities += service_identity_ids
if service_identity_id:
computed_identities.append(service_identity_id)
# de-dup
computed_identities = list(set(computed_identities))
response = self.britive.post(f'{self.base_url}/disabled-statuses', json=computed_identities)
if not service_identity_ids:
return response[0]
return response
|
class A:
def method(self):
print('This belongs to class A')
class B(A):
def method(self):
print('This belongs to class B')
pass
class C(A):
def method(self):
print('This belongs to class C')
pass
class D(B,C):
def method(self):
print('This belongs to class D')
pass
d = D()
d.method()
|
def astr(jour, mois):
if (mois == 3 and (jour >= 21 and jour <= 31)) or (mois == 4 and (jour >= 1 and jour <= 20)):
return "Belier"
elif (mois == 4 and (jour >= 21 and jour <= 30) or (mois == 5 and (jour >= 1 and jour <= 21))):
return "Taureau"
elif (mois == 5 and (jour >= 22 and jour <= 31) or (mois == 6 and (jour >= 1 and jour <= 21))):
return "Gemeaux"
elif (mois == 6 and (jour >= 23 and jour <= 30) or (mois == 7 and (jour >= 1 and jour <= 22))):
return "Cancer"
elif (mois == 7 and (jour >= 23 and jour <= 31) or (mois == 8 and (jour >= 1 and jour <= 22))):
return "Lion"
elif (mois == 8 and (jour >= 23 and jour <= 30) or (mois == 9 and (jour >= 1 and jour <= 22))):
return "Vierge"
elif (mois == 9 and (jour >= 23 and jour <= 31) or (mois == 10 and (jour >= 1 and jour <= 22))):
return "Balance"
elif (mois == 10 and (jour >= 23 and jour <= 30) or (mois == 11 and (jour >= 1 and jour <= 22))):
return "Scorpion"
elif (mois == 11 and (jour >= 23 and jour <= 31) or (mois == 12 and (jour >= 1 and jour <= 21))):
return "Sagittaire"
elif (mois == 12 and (jour >= 22 and jour <= 30) or (mois == 1 and (jour >= 1 and jour <= 20))):
return "Capricorne"
elif (mois == 1 and (jour >= 21 and jour <= 31) or (mois == 2 and (jour >= 1 and jour <= 19))):
return "Verseau"
elif (mois == 2 and (jour >= 20 and jour <= 30) or (mois == 3 and (jour >= 1 and jour <= 20))):
return "Poisson"
else:
"Erreur"
jour = int(input("Entrer le jour: "))
mois = int(input("Entrer le mois: "))
#ckeck before printed
print("Votre signe astrologique est: " + astr(jour, mois))
|
"""
4.3 – Contando até vinte: Use um laço for para exibir os números de 1 a 20,
incluindo-os.
"""
for num in range(1, 21):
print(num)
|
# Given a singly linked list, write a function which takes in the first node
# in a singly linked list and returns a boolean indicating if the linked list
# contains a "cycle".
# A cycle is when a node's next point actually points back to a previous node
# in the list. This is also sometimes known as a circularly linked list.
# Definition for singly-linked list.
# class ListNode(object):
# def __init__(self, x):
# self.val = x
# self.next = None
class Solution(object):
def hasCycle(self, head):
"""
:type head: ListNode
:rtype: bool
"""
seen = set()
cur = head
while cur:
if cur in seen:
return True
seen.add(cur)
cur = cur.next
return False
|
class segmenter:
def __init__(self):
self.index_count = 0
self.Tx_buff = []
self.data = []
def load_data(self,s):
self.data = s
def append_data(self,s):
self.data.append(s)
def prep_buff(self):
self.index_count = 0
l = len(self.data)
diff = l - self.index_count
if diff <= 0:
self.Tx_buff = []
return 0
if diff>10:
rem = 10
else:
rem = diff
self.Tx_buff = self.data[self.index_count:self.index_count+rem]
self.index_count = self.index_count + rem
self.data = self.data[self.index_count:]
return 1
def generate_data(self):
flag = self.prep_buff()
ret = []
if not flag:
return ret
else:
for i in self.Tx_buff:
for j in i:
ret.append(j)
return ret
SEG = segmenter()
"""
str=[[1, 1, 1, 1, 1, 1],[1, 0, 1, 0, 1, 1],[0, 1, 0, 1, 1, 0],[1, 1, 0, 0, 0, 0],[1, 1, 0, 1, 1, 1],[1, 0,0, 0, 1, 1],
[1, 1, 1, 1, 1, 1],[1, 0, 1, 0, 1, 1],[0, 1, 0, 1, 1, 0],[1, 1, 0, 0, 0, 0],[1, 1, 0, 1, 1, 1],[1, 0,0, 0, 1, 1]]
SEG.load_data(str)
print(len(SEG.generate_data()))
print(len(SEG.generate_data()))
print(len(SEG.generate_data()))
"""
|
ano = int(input('Digite um ano: '))
if (ano%4==0 and ano%100!=0) or (ano%400==0):
print('O ano de {} é Bissexto!'.format(ano))
else:
print('O ano de {} NÃO é bissexto'.format(ano))
|
class Solution:
def flipAndInvertImage(self, image: List[List[int]]) -> List[List[int]]:
image_width = len(image)
for idx, row in enumerate(image):
image[idx] = []
for element in row:
image[idx] = [1 - element] + image[idx]
return image
|
N = int(input())
odds = [i for i in range(1, N+1) if i % 2 != 0]
result = []
for odd in odds:
z = []
for i in range(1, odd+1):
if odd % i == 0:
z.append(i)
if len(z) == 8:
result.append(z)
print(len(result))
|
# -*- coding: utf-8 -*- voir https://docs.python.org/2/tutorial/interpreter.html#source-code-encoding
def interface(jeu):
"""Retourne les éléments de l'interface pour le menu "Game Over", défini également les boutons dans la variable jeu.
Paramètre:
- dict jeu: Dictionnaire contenant les valeurs associé au jeu.
Retourne:
- dict: Dictionnaire comportant les éléments de l'interface.
"""
jeu["boutons"] = ["Recommencer", "Menu Principal"]
sous_titre = "Score: " + str(jeu["score"])
if jeu["score"] > jeu["sauvegarde"]["record"]:
sous_titre += "\n*NOUVEAU RECORD*" # Met en valeur le score si c'est un nouveau record
return {
"titre": "Game Over",
"sous_titre": sous_titre
}
def boutons(jeu):
"""Permet au joueur d'intéragir avec les boutons du menu principal.
Paramètre:
- dict jeu: Dictionnaire contenant les valeurs associé au jeu.
"""
if jeu["score"] > jeu["sauvegarde"]["record"]:
jeu["sauvegarde"]["record"] = jeu["score"] # Met à jour le record s'il est supérieur à l'ancien
jeu.pop("score")
if jeu["curseur"] == 0: # Bouton Recommencer
jeu["statut"] = 1
else: # Bouton Menu Principal
jeu["statut"] = 0
|
"""
0131. Palindrome Partitioning
Medium
Given a string s, partition s such that every substring of the partition is a palindrome.
Return all possible palindrome partitioning of s.
Example:
Input: "aab"
Output:
[
["aa","b"],
["a","a","b"]
]
"""
class Solution:
def partition(self, s: str) -> List[List[str]]:
res = []
self.helper(s, [], res)
return res
def helper(self, s, path, res):
if not s:
res.append(path)
return
for i in range(1, len(s)+1):
if s[:i] == s[:i][::-1]:
self.helper(s[i:], path+[s[:i]], res)
|
# 11 - Given 2 (integer) lists, calculate if they're equal element by element and print it on the terminal.
equal = True
L1 = [67, 82, 100, 28, 22, 68]
L2 = [18, 27, 33, 13, 83, 61]
n = len(L1)
for i in range(0, n):
if L1[i] != L2[i]:
equal = False
if equal:
print("Lists are equal.")
else:
print("Lists aren't equal.")
|
"""
@Pedro Santana Abreu (https://linktr.ee/pedrosantanaabreu)
@Curso em Vídeo (https://cursoemvideo.com)
PT-BR:
Escreva um programa que leia a velocidade de um carro.
Se ele ultrapassar 80Km/h, mostre uma mensagem dizendo que ele foi multado.
A multa vai custar R$7,00 por cada Km acima do limite.
"""
# Recebendo informações
velocidade = int(input('Digite a velocidade do carro(em km): '))
# Se maior que 80
if velocidade > 80:
ultrapassou = velocidade - 80
multa = ultrapassou * 7
print('Você ultrapassou {:.0f}km do permitido e vai passar uma multa de: {:.2f} reais'.format(ultrapassou, multa))
# Caso contrario
else:
print('Voce não ultrapassou a velocidade')
|
"""
1. Lambda definition
"""
# def add(a, b):
# return a + b
# Lambda with name
add = lambda a,b : a + b
c = add(3, 5)
print(c)
# Anonymous Lambda
result = (lambda a, b: a + b)(9, 10)
print(result)
|
# pylint: disable=invalid-name
VERSION = '1.0'
default_app_config = 'django_walletpass.apps.DjangoWalletpassConfig'
|
#
# Example file for working with conditional statements
# (For Python 3.x, be sure to use the ExampleSnippets3.txt file)
def main():
x, y = 10, 100
if x < y :
str = "x is less than y"
elif x > y:
str = "y is less than x";
else:
str = "x is equal to y"
print(str)
st = "x is less than y" if x < y else "x is greater than or equal to y"
print(st)
if __name__ == "__main__":
main()
|
"""
Create by yy on 2019/9/21
"""
__title__ = 'psql-yy'
__description__ = 'A tool which is used to connect postgresql, designed by yy'
__url__ = 'https://github.com/guaidashu/psql_yy'
__version_info__ = ('0', '1', '6')
__version__ = '.'.join(__version_info__)
__author__ = 'guaidashu'
__author_email__ = 'song42960@gmail.com'
__maintainer__ = 'YY blog'
__license__ = 'MIT'
__copyright__ = '(c) 2019 by guaidashu'
__install_requires__ = [
"psycopg2 <= 2.8.3"
]
|
# Trie Node
class TrieNode:
def __init__(self, letter):
self.letter = letter
self.children = {}
self.is_end_of_word = False
class Trie:
def __init__(self):
self.root = TrieNode("*") # Root node
# ------------------------------------------------------------------------------------------
# Add words to trie
def add(self, word):
curr_node = self.root # Keep track of current node
for letter in word: # Add every letter if current node children doesn't have that letter
if letter not in curr_node.children:
curr_node.children[letter] = TrieNode(letter)
curr_node = curr_node.children[letter]
curr_node.is_end_of_word = True # Mark as end of word
# ------------------------------------------------------------------------------------------
# Search elements in trie
def search(self, word):
if word == "": # Empty string always exists
return True
curr_node = self.root
for letter in word:
if letter not in curr_node.children: # If letter is not present
return False
curr_node = curr_node.children[letter] # Update current node
return curr_node.is_end_of_word
# ------------------------------------------------------------------------------------------
# Display all words in trie
def show(self, node, word):
if node.is_end_of_word: # If end of word print the word
print(word, end =" ")
for l,n in node.children.items(): # Traverse for all the children in the node
self.show(n, word + l) # L -> Current letter, N -> Next node
if __name__ == "__main__":
trie = Trie()
words = ["wait", "waiter", "shop", "shopper"]
for word in words:
trie.add(word)
print(trie.search("wait"))
print(trie.search("waiter"))
print(trie.search(""))
print(trie.search("wai"))
trie.show(trie.root, "")
'''
Output
True
True
True
False
wait waiter shop shopper
'''
|
#
# PySNMP MIB module AT-DHCPSN-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/AT-DHCPSN-MIB
# Produced by pysmi-0.3.4 at Wed May 1 11:29:42 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Mar 27 2019, 09:23:15)
#
OctetString, ObjectIdentifier, Integer = mibBuilder.importSymbols("ASN1", "OctetString", "ObjectIdentifier", "Integer")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
SingleValueConstraint, ConstraintsIntersection, ValueSizeConstraint, ValueRangeConstraint, ConstraintsUnion = mibBuilder.importSymbols("ASN1-REFINEMENT", "SingleValueConstraint", "ConstraintsIntersection", "ValueSizeConstraint", "ValueRangeConstraint", "ConstraintsUnion")
modules, = mibBuilder.importSymbols("AT-SMI-MIB", "modules")
NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance")
TimeTicks, Integer32, MibIdentifier, IpAddress, MibScalar, MibTable, MibTableRow, MibTableColumn, iso, Counter32, ModuleIdentity, Counter64, Unsigned32, ObjectIdentity, Bits, Gauge32, NotificationType = mibBuilder.importSymbols("SNMPv2-SMI", "TimeTicks", "Integer32", "MibIdentifier", "IpAddress", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "iso", "Counter32", "ModuleIdentity", "Counter64", "Unsigned32", "ObjectIdentity", "Bits", "Gauge32", "NotificationType")
TextualConvention, DisplayString = mibBuilder.importSymbols("SNMPv2-TC", "TextualConvention", "DisplayString")
atDhcpsn = ModuleIdentity((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537))
atDhcpsn.setRevisions(('2010-09-07 00:00', '2010-06-14 04:45', '2010-02-09 01:30', '2009-12-10 01:30',))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
if mibBuilder.loadTexts: atDhcpsn.setRevisionsDescriptions(('Generic syntax tidy up', 'MIB revision history dates in descriptions updated.', 'This MIB file contains definitions of managed objects for DHCP Snooping in AlliedWare Plus.', 'Initial Revision',))
if mibBuilder.loadTexts: atDhcpsn.setLastUpdated('201009070000Z')
if mibBuilder.loadTexts: atDhcpsn.setOrganization('Allied Telesis, Inc')
if mibBuilder.loadTexts: atDhcpsn.setContactInfo('http://www.alliedtelesis.com')
if mibBuilder.loadTexts: atDhcpsn.setDescription('Added two more violation types for DHCP Snooping.')
atDhcpsnEvents = MibIdentifier((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 0))
atDhcpsnTrap = NotificationType((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 0, 1)).setObjects(("AT-DHCPSN-MIB", "atDhcpsnIfIndex"), ("AT-DHCPSN-MIB", "atDhcpsnVid"), ("AT-DHCPSN-MIB", "atDhcpsnSmac"), ("AT-DHCPSN-MIB", "atDhcpsnOpcode"), ("AT-DHCPSN-MIB", "atDhcpsnCiaddr"), ("AT-DHCPSN-MIB", "atDhcpsnYiaddr"), ("AT-DHCPSN-MIB", "atDhcpsnGiaddr"), ("AT-DHCPSN-MIB", "atDhcpsnSiaddr"), ("AT-DHCPSN-MIB", "atDhcpsnChaddr"), ("AT-DHCPSN-MIB", "atDhcpsnVioType"))
if mibBuilder.loadTexts: atDhcpsnTrap.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnTrap.setDescription('DHCP Snooping violation trap.')
atArpsecTrap = NotificationType((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 0, 2)).setObjects(("AT-DHCPSN-MIB", "atArpsecIfIndex"), ("AT-DHCPSN-MIB", "atArpsecClientIP"), ("AT-DHCPSN-MIB", "atArpsecSrcMac"), ("AT-DHCPSN-MIB", "atArpsecVid"), ("AT-DHCPSN-MIB", "atArpsecVioType"))
if mibBuilder.loadTexts: atArpsecTrap.setStatus('current')
if mibBuilder.loadTexts: atArpsecTrap.setDescription('DHCP Snooping ARP Security violation trap.')
atDhcpsnVariablesTable = MibTable((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1), )
if mibBuilder.loadTexts: atDhcpsnVariablesTable.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnVariablesTable.setDescription('This table contains rows of DHCP Snooping information.')
atDhcpsnVariablesEntry = MibTableRow((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1), ).setIndexNames((0, "AT-DHCPSN-MIB", "atDhcpsnIfIndex"))
if mibBuilder.loadTexts: atDhcpsnVariablesEntry.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnVariablesEntry.setDescription('A set of parameters that describe the DHCP Snooping features.')
atDhcpsnIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnIfIndex.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnIfIndex.setDescription('Ifindex of the port that the packet was received on.')
atDhcpsnVid = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnVid.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnVid.setDescription('VLAN ID of the port that the packet was received on.')
atDhcpsnSmac = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 3), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnSmac.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnSmac.setDescription('Source MAC address of the packet that caused the trap.')
atDhcpsnOpcode = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 4), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("bootpRequest", 1), ("bootpReply", 2)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnOpcode.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnOpcode.setDescription('Opcode value of the BOOTP packet that caused the trap. Only bootpRequest(1) or bootpReply(2) is valid.')
atDhcpsnCiaddr = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 5), IpAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnCiaddr.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnCiaddr.setDescription('Ciaddr value of the BOOTP packet that caused the trap.')
atDhcpsnYiaddr = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 6), IpAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnYiaddr.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnYiaddr.setDescription('Yiaddr value of the BOOTP packet that caused the trap.')
atDhcpsnGiaddr = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 7), IpAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnGiaddr.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnGiaddr.setDescription('Giaddr value of the BOOTP packet that caused the trap.')
atDhcpsnSiaddr = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 8), IpAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnSiaddr.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnSiaddr.setDescription('Siaddr value of the BOOTP packet that caused the trap.')
atDhcpsnChaddr = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 9), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnChaddr.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnChaddr.setDescription('Chaddr value of the BOOTP packet that caused the trap.')
atDhcpsnVioType = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 1, 1, 10), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13))).clone(namedValues=NamedValues(("invalidBootp", 1), ("invalidDhcpAck", 2), ("invalidDhcpRelDec", 3), ("invalidIp", 4), ("maxBindExceeded", 5), ("opt82InsertErr", 6), ("opt82RxInvalid", 7), ("opt82RxUntrusted", 8), ("opt82TxUntrusted", 9), ("replyRxUntrusted", 10), ("srcMacChaddrMismatch", 11), ("staticEntryExisted", 12), ("dbAddErr", 13)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: atDhcpsnVioType.setStatus('current')
if mibBuilder.loadTexts: atDhcpsnVioType.setDescription('The reason that the trap was generated. invalidBootp(1) indicates that the received BOOTP packet was invalid. For example, it is neither BootpRequest nor BootpReply. invalidDhcpAck(2) indicates that the received DHCP ACK was invalid. invalidDhcpRelDec(3) indicates the DHCP Release or Decline was invalid. invalidIp(4) indicates that the received IP packet was invalid. maxBindExceeded(5) indicates that if the entry was added, the maximum bindings configured for the port would be exceeded. opt82InsertErr(6) indicates that the insertion of Option 82 failed. opt82RxInvalid(7) indicates that the received Option 82 information was invalid. opt82RxUntrusted(8) indicates that Option 82 information was received on an untrusted port. opt82TxUntrusted(9) indicates that Option 82 would have been transmitted out an untrusted port. replyRxUntrusted(10) indicates that a BOOTP Reply was received on an untrusted port. srcMacChaddrMismatch(11) indicates that the source MAC address of the packet did not match the BOOTP CHADDR of the packet. staticEntryExisted(12) indicates that the static entry to be added already exists. dbAddErr(13) indicates that adding an entry to the database failed.')
atArpsecVariablesTable = MibTable((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 2), )
if mibBuilder.loadTexts: atArpsecVariablesTable.setStatus('current')
if mibBuilder.loadTexts: atArpsecVariablesTable.setDescription('This table contains rows of DHCP Snooping ARP Security information.')
atArpsecVariablesEntry = MibTableRow((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 2, 1), ).setIndexNames((0, "AT-DHCPSN-MIB", "atArpsecIfIndex"))
if mibBuilder.loadTexts: atArpsecVariablesEntry.setStatus('current')
if mibBuilder.loadTexts: atArpsecVariablesEntry.setDescription('A set of parameters that describe the DHCP Snooping ARP Security features.')
atArpsecIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 2, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: atArpsecIfIndex.setStatus('current')
if mibBuilder.loadTexts: atArpsecIfIndex.setDescription('Ifindex of the port that the ARP packet was received on.')
atArpsecClientIP = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 2, 1, 2), IpAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atArpsecClientIP.setStatus('current')
if mibBuilder.loadTexts: atArpsecClientIP.setDescription('Source IP address of the ARP packet.')
atArpsecSrcMac = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 2, 1, 3), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atArpsecSrcMac.setStatus('current')
if mibBuilder.loadTexts: atArpsecSrcMac.setDescription('Source MAC address of the ARP packet.')
atArpsecVid = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 2, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: atArpsecVid.setStatus('current')
if mibBuilder.loadTexts: atArpsecVid.setDescription('VLAN ID of the port that the ARP packet was received on.')
atArpsecVioType = MibTableColumn((1, 3, 6, 1, 4, 1, 207, 8, 4, 4, 4, 537, 2, 1, 5), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("srcIpNotFound", 1), ("badVLAN", 2), ("badPort", 3), ("srcIpNotAllocated", 4)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: atArpsecVioType.setStatus('current')
if mibBuilder.loadTexts: atArpsecVioType.setDescription('The reason that the trap was generated. srcIpNotFound(1) indicates that the Sender IP address of the ARP packet was not found in the DHCP Snooping database. badVLAN(2) indicates that the VLAN of the DHCP Snooping binding entry associated with the Sender IP address of the ARP packet does not match the VLAN that the ARP packet was received on. badPort(3) indicates that the port of the DHCP Snooping binding entry associated with the Sender IP address of the ARP packet does not match the port that the ARP packet was received on. srcIpNotAllocated(4) indicates that the CHADDR of the DHCP Snooping binding entry associated with the Sender IP address of the ARP packet does not match the Source MAC and/or the ARP source MAC of the ARP packet.')
mibBuilder.exportSymbols("AT-DHCPSN-MIB", atArpsecClientIP=atArpsecClientIP, atDhcpsnEvents=atDhcpsnEvents, atArpsecSrcMac=atArpsecSrcMac, atDhcpsnVid=atDhcpsnVid, atDhcpsnCiaddr=atDhcpsnCiaddr, atDhcpsnSmac=atDhcpsnSmac, atArpsecTrap=atArpsecTrap, atArpsecVariablesTable=atArpsecVariablesTable, atArpsecVioType=atArpsecVioType, atDhcpsnOpcode=atDhcpsnOpcode, atDhcpsnChaddr=atDhcpsnChaddr, atDhcpsnVariablesEntry=atDhcpsnVariablesEntry, atDhcpsnGiaddr=atDhcpsnGiaddr, atArpsecVariablesEntry=atArpsecVariablesEntry, atDhcpsnSiaddr=atDhcpsnSiaddr, atDhcpsnYiaddr=atDhcpsnYiaddr, atDhcpsnVioType=atDhcpsnVioType, atDhcpsnIfIndex=atDhcpsnIfIndex, PYSNMP_MODULE_ID=atDhcpsn, atDhcpsnVariablesTable=atDhcpsnVariablesTable, atDhcpsn=atDhcpsn, atDhcpsnTrap=atDhcpsnTrap, atArpsecIfIndex=atArpsecIfIndex, atArpsecVid=atArpsecVid)
|
# From dashcore-lib
class SimplifiedMNList:
pass
class SimplifiedMNListDiff:
pass
class MerkleBlock:
pass
class BlockHeader:
pass
|
class Provider(BaseProvider):
""" Generates fake ISBNs. ISBN rules vary across languages/regions
so this class makes no attempt at replicating all of the rules. It
only replicates the 978 EAN prefix for the English registration
groups, meaning the first 4 digits of the ISBN-13 will either be
978-0 or 978-1. Since we are only replicating 978 prefixes, every
ISBN-13 will have a direct mapping to an ISBN-10.
See https://www.isbn-international.org/content/what-isbn for the
format of ISBNs.
See https://www.isbn-international.org/range_file_generation for the
list of rules pertaining to each prefix/registration group.
"""
def _body(self):
""" Generate the information required to create an ISBN-10 or
ISBN-13.
"""
ean = self.random_element(RULES.keys())
reg_group = self.random_element(RULES[ean].keys())
reg_pub_len = ISBN.MAX_LENGTH - len(ean) - len(reg_group) - 1
reg_pub = self.numerify("#" * reg_pub_len)
rules = RULES[ean][reg_group]
registrant, publication = self._registrant_publication(reg_pub, rules)
return [ean, reg_group, registrant, publication]
@staticmethod
def _registrant_publication(reg_pub, rules):
""" Separate the registration from the publication in a given
string.
:param reg_pub: A string of digits representing a registration
and publication.
:param rules: A list of RegistrantRules which designate where
to separate the values in the string.
:returns: A (registrant, publication) tuple of strings.
"""
for rule in rules:
if rule.min <= reg_pub <= rule.max:
reg_len = rule.registrant_length
break
else:
raise Exception("Registrant/Publication not found in registrant " "rule list.")
registrant, publication = reg_pub[:reg_len], reg_pub[reg_len:]
return registrant, publication
def isbn13(self, separator="-"):
ean, group, registrant, publication = self._body()
isbn = ISBN13(ean, group, registrant, publication)
return isbn.format(separator)
def isbn10(self, separator="-"):
ean, group, registrant, publication = self._body()
isbn = ISBN10(ean, group, registrant, publication)
return isbn.format(separator)
|
class TexFile:
"""Represents a body of .tex template. Can change its
parameters and gives you body for captions and formulas.
List of parameters:
sans_font: Set sans font of the document.
roman_font, mono_font: The same.
pre_packages: These packages will be included into preamble at its
beginning. Is array.
post_packages: Packages to place at the end of preamble. Is array.
To change or unset these parameters use unset_prop() and set_prop() methods.
If parameter is array, just use append_prop().
"""
def __init__(self, file_address):
self.origin_body = open(file_address).read()
self.templated_body = None
self.state = {
"sans_font": False,
"roman_font": False,
"mono_font": False,
"pre_packages": [],
"post_packages": []
}
self.is_formula = False
def unset_prop(self, name: str):
# I think no need to catch exception here
self.state[name] = (
[]
if isinstance(self.state[name], list)
else False
)
def set_prop(self, name: str, value):
self.state[name] = value
def append_prop(self, name: str, value):
"""Use this method instead of set_prop if the parameter is an array.
"""
self.state[name].append(value)
def reapply_templates(self):
"""Remember body with applied parameters. This function can be called
if they was changed.
"""
self.templated_body = str(self.origin_body)
for label, value in self.state.items():
if not value:
continue
replace_by = ""
if label == "sans_font":
replace_by = (
"\\setsansfont[Mapping=tex-text]{%s}" % value
)
elif label == "roman_font":
replace_by = (
"\\setromanfont[Mapping=tex-text]{%s}" % value
)
elif label == "mono_font":
replace_by = (
"\\setmonofont[Mapping=tex-text]{%s}" % value
)
elif label in ["pre_packages", "post_packages"]:
replace_by = "\n".join([
"\\usepackage{%s}" % package
for package in value
])
self.templated_body = self.templated_body.replace(
"%%!template:%s" % label, replace_by
)
def get_body(self, caption: str) -> str:
return self.templated_body.replace(
"%!template:content", caption)
def get_aligned_body(self, formula: str) -> str:
return self.templated_body.replace(
"%!template:content",
"\\begin{align*}\n%s\n\\end{align*}" % formula
)
def configurate(self, config):
"""Set self.state to configs given in `config`.
"""
for key in self.state.keys():
if key in config:
self.state[key] = config[key] or False
self.reapply_templates()
|
# Operadores Aritméticos
print('Multiplicação *', 10*10) # quando usados numeros, são operadores normais.
print('Mutiplicação * ', 10* 'A') # quando usados com strings, eles servem ocmo repetidores.
print('Adção + ', 10+10) # quando usados numeros é feita a soma, mas quando usados strings é feita a concatenação.
print('Subtração -', 10 -5)
print('Divisão / ', 10 / 3)
print('Divisão Inteira //', 10 // 3)
print('Divisão Modulo %', 10 % 3)
print('Potenciação **', 2**4)
# Ordem de procedência
"""
( n + n ) - Os parênteses têm a maior precedência, contas dentro deles são realizadas primeiro
** - Depois vem a exponenciação
* / // % - Na sequência multiplicação, divisão, divisão inteira e módulo
+ - - Por fim, soma e subtração
"""
|
# Listas são criadas com []
lista = ["item 1", "item 2", "item 3"]
# Imprimir a lista
print(lista)
# Atribuir valores da lista à variáveis
v1 = lista[0]
v2 = lista[1]
v3 = lista[2]
# Imprimir apenas 1 item da lista
print(lista[0])
# Atualizar lista
lista[2] = "new item 3"
# Deletar um item da lista
del lista[1]
# Criar uma lista aninhada
# Em python, listas de listas são matrizes
matriz = [[1, 2, 3], [4, 5, 6], [7, 8, 9]]
# Atribuir um item da lista/matriz a uma variável
# O exemplo abaixo guardará [1, 2, 3]
a = matriz[0]
# Para guardar apenas 1 item
b = a[0]
# --------- OPERAÇÕES COM LISTAS ---------
# Atribuir à variável o valor da primeira linha e coluna da matriz
# [linha][coluna]
c = matriz[0][0]
# Operações
d = matriz[0][1] + 2
e = matriz[0][1] - 2
f = matriz[0][1] * 2
g = matriz[0][1] / 2
# Concatenar listas
lista1 = [1, 2, 3]
lista2 = [4, 5, 6]
lista_total = lista1
# --------- OPERADOR IN ---------
# Verificar se o número 5 está na lista
lista_teste = [1, 2, 3, 4, 5]
print(5 in lista_teste)
# --------- FUNÇÕES BUILT-IN ---------
# Retornar o comprimento da lista
len(lista_teste)
# Retorna o valor máximo da lista
max(lista_teste)
# Retornar o valor mínimo da lista
min(lista_teste)
# Adicionar um item à lista
lista_teste.append(6)
# Contar o número de ocorrências de um item em uma lista
lista_teste.count(2)
# Verificar o tipo
type(lista_teste)
# Copiar os itens de uma lista para outra
old_list = [1, 2, 3]
new_list = []
for i in old_list:
new_list.append(i)
# Adicionar itens ao final de uma lista
lista_teste.extend([4, 5, 6, 7])
# Retornar o índice de um item na lista
lista_teste.index(7)
# Inserir na posição 2, o valor 100
lista_teste.insert(2, 100)
# Remover um item da lista
lista_teste.remove(100)
# Reverter a lista
lista_teste.reverse()
# Ordenar a lista
lista_teste.sort()
|
# SPDX-License-Identifier: BSD-3-Clause
__all__ = (
'guid',
'GPT_PART_TYPES',
'UEFI_CORE_PART_TYPES' , 'WINDOWS_PART_TYPES' , 'HPUX_PART_TYPES' ,
'LINUX_PART_TYPES' , 'FREEBSD_PART_TYPES' , 'DARWIN_PART_TYPES' ,
'SOLARIS_PART_TYPES' , 'NETBSD_PART_TYPES' , 'CHROMEOS_PART_TYPES' ,
'COREOS_PART_TYPES' , 'HAIKU_PART_TYPES' , 'MIDNIGHT_PART_TYPES' ,
'CEPH_PART_TYPES' , 'OPENBSD_PART_TYPES' , 'QNX_PART_TYPES' ,
'PLAN9_PART_TYPES' , 'VMWARE_PART_TYPES' , 'ANDROID_IA_PART_TYPES',
'ANDROID_ARM_PART_TYPES', 'ONIE_PART_TYPES' , 'POWERPC_PART_TYPES' ,
'FREEDESKTOP_PART_TYPES', 'ATARI_TOS_PART_TYPES', 'VERACRYPT_PART_TYPES' ,
'OS2_PART_TYPES' , 'SPDK_PART_TYPES' , 'BAREBOX_PART_TYPES' ,
)
UEFI_CORE_PART_TYPES = {
'unused' : { # Unused GPT Partition
'data0': 0x00000000, 'data1': 0x0000,
'data2': 0x0000 , 'data3': 0x0000,
'data4': b'\x00\x00\x00\x00\x00\x00'
},
'esp' : { # EFI System Partition
'data0': 0xC12A7328, 'data1': 0xF81F,
'data2': 0x11D2 , 'data3': 0xBA4B,
'data4': b'\x00\xA0\xC9\x3E\xC9\x3B'
},
'mbr' : { # Legacy MBR Partition
'data0': 0x024DEE41, 'data1': 0x33E7,
'data2': 0x11D3 , 'data3': 0x9D69,
'data4': b'\x00\x08\xC7\x81\xF3\x9F'
},
'bios' : { # BIOS boot partition
'data0': 0x21686148, 'data1': 0x6449,
'data2': 0x6E6F , 'data3': 0x744E,
'data4': b'\x65\x65\x64\x45\x46\x49'
},
'iffs' : { # Intel Fast Flash (iFFS) partition (for Intel Rapid Start technology)
'data0': 0xD3BFE2DE, 'data1': 0x3DAF,
'data2': 0x11DF , 'data3': 0xBA40,
'data4': b'\xE3\xA5\x56\xD8\x95\x93'
},
'sony' : { # Sony boot partition
'data0': 0xF4019732, 'data1': 0x066E,
'data2': 0x4E12 , 'data3': 0x8273,
'data4': b'\x34\x6C\x56\x41\x49\x4F'
},
'lenovo' : { # Lenovo boot partition
'data0': 0xBFBFAFE7, 'data1': 0xA34F,
'data2': 0x448A , 'data3': 0x9A5B,
'data4': b'\x62\x13\xEB\x73\x6C\x22'
},
}
WINDOWS_PART_TYPES = {
'msr' : { # Microsoft Reserved Partition (MSR)
'data0': 0xE3C9E316, 'data1': 0x0B5C,
'data2': 0x4DB8 , 'data3': 0x817D,
'data4': b'\xF9\x2D\xF0\x02\x15\xAE'
},
'bdp' : { # Basic data partition
'data0': 0xEBD0A0A2, 'data1': 0xB9E5,
'data2': 0x4433 , 'data3': 0x87C0,
'data4': b'\x68\xB6\xB7\x26\x99\xC7'
},
'ldmmeta': { # Logical Disk Manager (LDM) metadata partition
'data0': 0x5808C8AA, 'data1': 0x7E8F,
'data2': 0x42E0 , 'data3': 0x85D2,
'data4': b'\xE1\xE9\x04\x34\xCF\xB3'
},
'ldm' : { # Logical Disk Manager data partition
'data0': 0xAF9B60A0, 'data1': 0x1431,
'data2': 0x4F62 , 'data3': 0xBC68,
'data4': b'\x33\x11\x71\x4A\x69\xAD'
},
'recover': { # Windows Recovery Environment
'data0': 0xDE94BBA4, 'data1': 0x06D1,
'data2': 0x4D40 , 'data3': 0xA16A,
'data4': b'\xBF\xD5\x01\x79\xD6\xAC'
},
'gpfs' : { # IBM General Parallel File System (GPFS) partition
'data0': 0x37AFFC90, 'data1': 0xEF7D,
'data2': 0x4E96 , 'data3': 0x91C3,
'data4': b'\x2D\x7A\xE0\x55\xB1\x74'
},
'sspace' : { # Storage Spaces partition
'data0': 0xE75CAF8F, 'data1': 0xF680,
'data2': 0x4CEE , 'data3': 0xAFA3,
'data4': b'\xB0\x01\xE5\x6E\xFC\x2D'
},
'sreplic': { # Storage Replica partition
'data0': 0x558D43C5, 'data1': 0xA1AC,
'data2': 0x43C0 , 'data3': 0xAAC8,
'data4': b'\xD1\x47\x2B\x29\x23\xD1'
},
}
HPUX_PART_TYPES = {
'data' : { # Data partition
'data0': 0x75894C1E, 'data1': 0x3AEB,
'data2': 0x11D3 , 'data3': 0xB7C1,
'data4': b'\x7B\x03\xA0\x00\x00\x00'
},
'service': { # Service partition
'data0': 0xE2A1E728, 'data1': 0x32E3,
'data2': 0x11D6 , 'data3': 0xA682,
'data4': b'\x7B\x03\xA0\x00\x00\x00'
},
}
LINUX_PART_TYPES = {
'lfsd' : { # Linux filesystem data
'data0': 0x0FC63DAF, 'data1': 0x8483,
'data2': 0x4772 , 'data3': 0x8E79,
'data4': b'\x3D\x69\xD8\x47\x7D\xE4'
},
'raid' : { # RAID partition
'data0': 0xA19D880F, 'data1': 0x05FC,
'data2': 0x4D3B , 'data3': 0x0000,
'data4': b'\x74\x3F\x0F\x84\x91\x1E'
},
'rootx32': { # Root partition (x86)
'data0': 0x44479540, 'data1': 0xF297,
'data2': 0x41B2 , 'data3': 0x0000,
'data4': b'\xD1\x31\xD5\xF0\x45\x8A'
},
'rootx64': { # Root partition (x86-64)
'data0': 0x4F68BCE3, 'data1': 0xE8CD,
'data2': 0x4DB1 , 'data3': 0x0000,
'data4': b'\xFB\xCA\xF9\x84\xB7\x09'
},
'roota32': { # Root partition (32-bit ARM)
'data0': 0x69DAD710, 'data1': 0x2CE4,
'data2': 0x4E3C , 'data3': 0x0000,
'data4': b'\x21\xA1\xD4\x9A\xBE\xD3'
},
'roota64': { # Root partition (64-bit ARM/AArch64)
'data0': 0xB921B045, 'data1': 0x1DF0,
'data2': 0x41C3 , 'data3': 0x0000,
'data4': b'\x4C\x6F\x28\x0D\x3F\xAE'
},
'boot' : { # /boot partition
'data0': 0xBC13C2FF, 'data1': 0x59E6,
'data2': 0x4262 , 'data3': 0x0000,
'data4': b'\xB2\x75\xFD\x6F\x71\x72'
},
'swap' : { # Swap partition
'data0': 0x0657FD6D, 'data1': 0xA4AB,
'data2': 0x43C4 , 'data3': 0x0000,
'data4': b'\x09\x33\xC8\x4B\x4F\x4F'
},
'lvm' : { # Logical Volume Manager (LVM) partition
'data0': 0xE6D6D379, 'data1': 0xF507,
'data2': 0x44C2 , 'data3': 0x0000,
'data4': b'\x23\x8F\x2A\x3D\xF9\x28'
},
'home' : { # /home partition
'data0': 0x933AC7E1, 'data1': 0x2EB4,
'data2': 0x4F13 , 'data3': 0x0000,
'data4': b'\x0E\x14\xE2\xAE\xF9\x15'
},
'srv' : { # /srv (server data) partition
'data0': 0x3B8F8425, 'data1': 0x20E0,
'data2': 0x4F3B , 'data3': 0x0000,
'data4': b'\x1A\x25\xA7\x6F\x98\xE8'
},
'dmcrypt': { # Plain dm-crypt partition
'data0': 0x7FFEC5C9, 'data1': 0x2D00,
'data2': 0x49B7 , 'data3': 0x0000,
'data4': b'\x3E\xA1\x0A\x55\x86\xB7'
},
'luks' : { # LUKS partition
'data0': 0xCA7D7CCB, 'data1': 0x63ED,
'data2': 0x4C53 , 'data3': 0x0000,
'data4': b'\x17\x42\x53\x60\x59\xCC'
},
'res' : { # Reserved
'data0': 0x8DA63339, 'data1': 0x0007,
'data2': 0x60C0 , 'data3': 0x0000,
'data4': b'\x08\x3A\xC8\x23\x09\x08'
},
}
FREEBSD_PART_TYPES = {
'boot' : { # Boot partition
'data0': 0x83BD6B9D, 'data1': 0x7F41,
'data2': 0x11DC , 'data3': 0xBE0B,
'data4': b'\x00\x15\x60\xB8\x4F\x0F'
},
'data' : { # Data partition
'data0': 0x516E7CB4, 'data1': 0x6ECF,
'data2': 0x11D6 , 'data3': 0x8FF8,
'data4': b'\x00\x02\x2D\x09\x71\x2B'
},
'swap' : { # Swap partition
'data0': 0x516E7CB5, 'data1': 0x6ECF,
'data2': 0x11D6 , 'data3': 0x8FF8,
'data4': b'\x00\x02\x2D\x09\x71\x2B'
},
'ufs' : { # Unix File System (UFS) partition
'data0': 0x516E7CB6, 'data1': 0x6ECF,
'data2': 0x11D6 , 'data3': 0x8FF8,
'data4': b'\x00\x02\x2D\x09\x71\x2B'
},
'vinum' : { # Vinum volume manager partition
'data0': 0x516E7CB8, 'data1': 0x6ECF,
'data2': 0x11D6 , 'data3': 0x8FF8,
'data4': b'\x00\x02\x2D\x09\x71\x2B'
},
'zfs' : { # ZFS partition
'data0': 0x516E7CBA, 'data1': 0x6ECF,
'data2': 0x11D6 , 'data3': 0x8FF8,
'data4': b'\x00\x02\x2D\x09\x71\x2B'
},
}
DARWIN_PART_TYPES = {
'hfs' : { # Hierarchical File System Plus (HFS+) partition
'data0': 0x48465300, 'data1': 0x0000,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'apfs' : { # Apple APFS container / APFS FileVault volume container
'data0': 0x7C3457EF, 'data1': 0x0000,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'ufs' : { # Apple UFS container
'data0': 0x55465300, 'data1': 0x0000,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'zfs' : { # ZFS
'data0': 0x6A898CC3, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'araid' : { # Apple RAID partition
'data0': 0x52414944, 'data1': 0x0000,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'araid_o': { # Apple RAID partition, offline
'data0': 0x52414944, 'data1': 0x5F4F,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'boot' : { # Apple Boot partition (Recovery HD)
'data0': 0x426F6F74, 'data1': 0x0000,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'label' : { # Apple Label
'data0': 0x4C616265, 'data1': 0x6C00,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'tv' : { # Apple TV Recovery partition
'data0': 0x5265636F, 'data1': 0x7665,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'core' : { # Apple Core Storage Container / HFS+ FileVault volume container
'data0': 0x53746F72, 'data1': 0x6167,
'data2': 0x11AA , 'data3': 0xAA11,
'data4': b'\x00\x30\x65\x43\xEC\xAC'
},
'sr_stat': { # SoftRAID_Status
'data0': 0xB6FA30DA, 'data1': 0x92D2,
'data2': 0x4A9A , 'data3': 0x96F1,
'data4': b'\x87\x1E\xC6\x48\x62\x00'
},
'sr_scra': { # SoftRAID_Scratch
'data0': 0x2E313465, 'data1': 0x19B9,
'data2': 0x463F , 'data3': 0x8126,
'data4': b'\x8A\x79\x93\x77\x38\x01'
},
'sr_vol' : { # SoftRAID_Volume
'data0': 0xFA709C7E, 'data1': 0x65B1,
'data2': 0x4593 , 'data3': 0xBFD5,
'data4': b'\xE7\x1D\x61\xDE\x9B\x02'
},
'sr_cach': { # SoftRAID_Cache
'data0': 0xBBBA6DF5, 'data1': 0xF46F,
'data2': 0x4A89 , 'data3': 0x8F59,
'data4': b'\x87\x65\xB2\x72\x75\x03'
},
}
SOLARIS_PART_TYPES = {
'boot' : { # Boot partition
'data0': 0x6A82CB45, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'root' : { # Root partition
'data0': 0x6A85CF4D, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'swap' : { # Swap partition
'data0': 0x6A87C46F, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'backup' : { # Backup partition
'data0': 0x6A8B642B, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'usr' : { # /usr partition
'data0': 0x6A898CC3, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'var' : { # /var partition
'data0': 0x6A8EF2E9, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'home' : { # /home partition
'data0': 0x6A90BA39, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'alt' : { # Alternate sector
'data0': 0x6A9283A5, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'res1' : { # Reserved partition
'data0': 0x6A945A3B, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'res2' : { # Reserved partition
'data0': 0x6A9630D1, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'res3' : { # Reserved partition
'data0': 0x6A980767, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'res4' : { # Reserved partition
'data0': 0x6A96237F, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
'res5' : { # Reserved partition
'data0': 0x6A8D2AC7, 'data1': 0x1DD2,
'data2': 0x11B2 , 'data3': 0x99A6,
'data4': b'\x08\x00\x20\x73\x66\x31'
},
}
NETBSD_PART_TYPES = {
'swap' : { # Swap partition
'data0': 0x49F48D32, 'data1': 0xB10E,
'data2': 0x11DC , 'data3': 0xB99B,
'data4': b'\x00\x19\xD1\x87\x96\x48'
},
'ffs' : { # FFS partition
'data0': 0x49F48D5A, 'data1': 0xB10E,
'data2': 0x11DC , 'data3': 0xB99B,
'data4': b'\x00\x19\xD1\x87\x96\x48'
},
'lfs' : { # LFS partition
'data0': 0x49F48D82, 'data1': 0xB10E,
'data2': 0x11DC , 'data3': 0xB99B,
'data4': b'\x00\x19\xD1\x87\x96\x48'
},
'raid' : { # RAID partition
'data0': 0x49F48DAA, 'data1': 0xB10E,
'data2': 0x11DC , 'data3': 0xB99B,
'data4': b'\x00\x19\xD1\x87\x96\x48'
},
'cat' : { # Concatenated partition
'data0': 0x2DB519C4, 'data1': 0xB10F,
'data2': 0x11DC , 'data3': 0xB99B,
'data4': b'\x00\x19\xD1\x87\x96\x48'
},
'enc' : { # Encrypted partition
'data0': 0x2DB519EC, 'data1': 0xB10F,
'data2': 0x11DC , 'data3': 0xB99B,
'data4': b'\x00\x19\xD1\x87\x96\x48'
},
}
CHROMEOS_PART_TYPES = {
'kernel' : { # Chrome OS kernel
'data0': 0xFE3A2A5D, 'data1': 0x4F32,
'data2': 0x41A7 , 'data3': 0xB725,
'data4': b'\xAC\xCC\x32\x85\xA3\x09'
},
'root' : { # Chrome OS rootfs
'data0': 0x3CB8E202, 'data1': 0x3B7E,
'data2': 0x47DD , 'data3': 0x8A3C,
'data4': b'\x7F\xF2\xA1\x3C\xFC\xEC'
},
'future' : { # Chrome OS future use
'data0': 0x2E0A753D, 'data1': 0x9E48,
'data2': 0x43B0 , 'data3': 0x8337,
'data4': b'\xB1\x51\x92\xCB\x1B\x5E'
},
}
COREOS_PART_TYPES = {
'usr' : { # /usr partition (coreos-usr)
'data0': 0x5DFBF5F4, 'data1': 0x2848,
'data2': 0x4BAC , 'data3': 0xAA5E,
'data4': b'\x0D\x9A\x20\xB7\x45\xA6'
},
'root' : { # Resizable rootfs (coreos-resize)
'data0': 0x3884DD41, 'data1': 0x8582,
'data2': 0x4404 , 'data3': 0xB9A8,
'data4': b'\xE9\xB8\x4F\x2D\xF5\x0E'
},
'oem' : { # OEM customizations (coreos-reserved)
'data0': 0xC95DC21A, 'data1': 0xDF0E,
'data2': 0x4340 , 'data3': 0x8D7B,
'data4': b'\x26\xCB\xFA\x9A\x03\xE0'
},
'rroot' : { # Root filesystem on RAID (coreos-root-raid)
'data0': 0xBE9067B9, 'data1': 0xEA49,
'data2': 0x4F15 , 'data3': 0xB4F6,
'data4': b'\xF3\x6F\x8C\x9E\x18\x18'
},
}
HAIKU_PART_TYPES = {
'bfs' : { # Haiku BFS
'data0': 0x42465331, 'data1': 0x3BA3,
'data2': 0x10F1 , 'data3': 0x802A,
'data4': b'\x48\x61\x69\x6B\x75\x21'
},
}
MIDNIGHT_PART_TYPES = {
'boot' : { # Boot partition
'data0': 0x85D5E45E, 'data1': 0x237C,
'data2': 0x11E1 , 'data3': 0xB4B3,
'data4': b'\xE8\x9A\x8F\x7F\xC3\xA7'
},
'data' : { # Data partition
'data0': 0x85D5E45A, 'data1': 0x237C,
'data2': 0x11E1 , 'data3': 0xB4B3,
'data4': b'\xE8\x9A\x8F\x7F\xC3\xA7'
},
'swap' : { # Swap partition
'data0': 0x85D5E45B, 'data1': 0x237C,
'data2': 0x11E1 , 'data3': 0xB4B3,
'data4': b'\xE8\x9A\x8F\x7F\xC3\xA7'
},
'ufs' : { # Unix File System (UFS) partition
'data0': 0x0394EF8B, 'data1': 0x237E,
'data2': 0x11E1 , 'data3': 0xB4B3,
'data4': b'\xE8\x9A\x8F\x7F\xC3\xA7'
},
'vinum' : { # Vinum volume manager partition
'data0': 0x85D5E45C, 'data1': 0x237C,
'data2': 0x11E1 , 'data3': 0xB4B3,
'data4': b'\xE8\x9A\x8F\x7F\xC3\xA7'
},
'zfs' : { # ZFS partition
'data0': 0x85D5E45D, 'data1': 0x237C,
'data2': 0x11E1 , 'data3': 0xB4B3,
'data4': b'\xE8\x9A\x8F\x7F\xC3\xA7'
},
}
CEPH_PART_TYPES = {
'journ' : { # Journal
'data0': 0x45B0969E, 'data1': 0x9B03,
'data2': 0x0000 , 'data3': 0xB4C6,
'data4': b'\xB4\xB8\x0C\xEF\xF1\x06'
},
'djourn' : { # dm-crypt journal
'data0': 0x45B0969E, 'data1': 0x9B03,
'data2': 0x4F30 , 'data3': 0xB4C6,
'data4': b'\x5E\xC0\x0C\xEF\xF1\x06'
},
'osd' : { # OSD
'data0': 0x4FBD7E29, 'data1': 0x9D25,
'data2': 0x4F30 , 'data3': 0xAFD0,
'data4': b'\x06\x2C\x0C\xEF\xF0\x5D'
},
'dosd' : { # dm-crypt OSD
'data0': 0x4FBD7E29, 'data1': 0x9D25,
'data2': 0x41B8 , 'data3': 0xAFD0,
'data4': b'\x5E\xC0\x0C\xEF\xF0\x5D'
},
'dic' : { # Disk in creation
'data0': 0x89C57F98, 'data1': 0x2FE5,
'data2': 0x41B8 , 'data3': 0x89C1,
'data4': b'\xF3\xAD\x0C\xEF\xF2\xBE'
},
'ddic' : { # dm-crypt disk in creation
'data0': 0x89C57F98, 'data1': 0x2FE5,
'data2': 0x4DC0 , 'data3': 0x89C1,
'data4': b'\x5E\xC0\x0C\xEF\xF2\xBE'
},
'block' : { # Block
'data0': 0xCAFECAFE, 'data1': 0x9B03,
'data2': 0x4DC0 , 'data3': 0xB4C6,
'data4': b'\xB4\xB8\x0C\xEF\xF1\x06'
},
'blkdb' : { # Block DB
'data0': 0x30CD0809, 'data1': 0xC2B2,
'data2': 0x4F30 , 'data3': 0x8879,
'data4': b'\x2D\x6B\x78\x52\x98\x76'
},
'bwal' : { # Block write-ahead log
'data0': 0x5CE17FCE, 'data1': 0x4087,
'data2': 0x499C , 'data3': 0xB7FF,
'data4': b'\x05\x6C\xC5\x84\x73\xF9'
},
'dlwkbx' : { # Lockbox for dm-crypt keys
'data0': 0xFB3AABF9, 'data1': 0xD25F,
'data2': 0x4169 , 'data3': 0xBF5E,
'data4': b'\x72\x1D\x18\x16\x49\x6B'
},
'mosd' : { # Multipath OSD
'data0': 0x4FBD7E29, 'data1': 0x8AE0,
'data2': 0x47CC , 'data3': 0xBF9D,
'data4': b'\x5A\x8D\x86\x7A\xF5\x60'
},
'mjourn' : { # Multipath journal
'data0': 0x45B0969E, 'data1': 0x8AE0,
'data2': 0x4982 , 'data3': 0xBF9D,
'data4': b'\x5A\x8D\x86\x7A\xF5\x60'
},
'mblock1': { # Multipath block
'data0': 0xCAFECAFE, 'data1': 0x8AE0,
'data2': 0x4982 , 'data3': 0xBF9D,
'data4': b'\x5A\x8D\x86\x7A\xF5\x60'
},
'mblock2': { # Multipath block
'data0': 0x7F4A666A, 'data1': 0x16F3,
'data2': 0x4982 , 'data3': 0x8445,
'data4': b'\x15\x2E\xF4\xD0\x3F\x6C'
},
'mblkdb' : { # Multipath block DB
'data0': 0xEC6D6385, 'data1': 0xE346,
'data2': 0x47A2 , 'data3': 0xBE91,
'data4': b'\xDA\x2A\x7C\x8B\x32\x61'
},
'mbwal' : { # Multipath block write-ahead log
'data0': 0x01B41E1B, 'data1': 0x002A,
'data2': 0x45DC , 'data3': 0x9F17,
'data4': b'\x88\x79\x39\x89\xFF\x8F'
},
'dblock' : { # dm-crypt block
'data0': 0xCAFECAFE, 'data1': 0x9B03,
'data2': 0x0000 , 'data3': 0xB4C6,
'data4': b'\x5E\xC0\x0C\xEF\xF1\x06'
},
'dblkdb' : { # dm-crypt block DB
'data0': 0x93B0052D, 'data1': 0x02D9,
'data2': 0x453C , 'data3': 0xA43B,
'data4': b'\x33\xA3\xEE\x4D\xFB\xC3'
},
'dbwal' : { # dm-crypt block write-ahead log
'data0': 0x306E8683, 'data1': 0x4FE2,
'data2': 0x4F30 , 'data3': 0xB7C0,
'data4': b'\x00\xA9\x17\xC1\x69\x66'
},
'ljourn' : { # dm-crypt LUKS journal
'data0': 0x45B0969E, 'data1': 0x9B03,
'data2': 0x4D8A , 'data3': 0xB4C6,
'data4': b'\x35\x86\x5C\xEF\xF1\x06'
},
'lblock' : { # dm-crypt LUKS block
'data0': 0xCAFECAFE, 'data1': 0x9B03,
'data2': 0x4330 , 'data3': 0xB4C6,
'data4': b'\x35\x86\x5C\xEF\xF1\x06'
},
'lblkdb' : { # dm-crypt LUKS block DB
'data0': 0x166418DA, 'data1': 0xC469,
'data2': 0x4022 , 'data3': 0xADF4,
'data4': b'\xB3\x0A\xFD\x37\xF1\x76'
},
'lbwal' : { # dm-crypt LUKS block write-ahead log
'data0': 0x86A32090, 'data1': 0x3647,
'data2': 0x40B9 , 'data3': 0xBBBD,
'data4': b'\x38\xD8\xC5\x73\xAA\x86'
},
'losd' : { # dm-crypt LUKS OSD
'data0': 0x4FBD7E29, 'data1': 0x9D25,
'data2': 0x41B8 , 'data3': 0xAFD0,
'data4': b'\x35\x86\x5C\xEF\xF0\x5D'
},
}
OPENBSD_PART_TYPES = {
'data' : { # Data Partition
'data0': 0x824CC7A0, 'data1': 0x36A8,
'data2': 0x11E3 , 'data3': 0x890A,
'data4': b'\x95\x25\x19\xAD\x3F\x61'
},
}
QNX_PART_TYPES = {
'qnx6' : { # Power-safe (QNX6) Filesystem
'data0': 0xCEF5A9AD, 'data1': 0x73BC,
'data2': 0x4601 , 'data3': 0x89F3,
'data4': b'\xCD\xEE\xEE\xE3\x21\xA1'
},
}
PLAN9_PART_TYPES = {
'part' : { # Plan9 Partition
'data0': 0xC91818F9, 'data1': 0x8025,
'data2': 0x47AF , 'data3': 0x89D2,
'data4': b'\xF0\x30\xD7\x00\x0C\x2C'
},
}
VMWARE_PART_TYPES = {
'core' : { # vmkcore Coredump partition
'data0': 0x9D275380, 'data1': 0x40AD,
'data2': 0x11DB , 'data3': 0xBF97,
'data4': b'\x00\x0C\x29\x11\xD1\xB8'
},
'vmfs' : { # VMFS Filesystem Partition
'data0': 0xAA31E02A, 'data1': 0x400F,
'data2': 0x11DB , 'data3': 0x9590,
'data4': b'\x00\x0C\x29\x11\xD1\xB8'
},
'res' : { # VMWareReserved
'data0': 0x9198EFFC, 'data1': 0x31C0,
'data2': 0x11DB , 'data3': 0x8F78,
'data4': b'\x00\x0C\x29\x11\xD1\xB8'
},
}
ANDROID_IA_PART_TYPES = {
'bootl1' : { # Android Bootloader 1
'data0': 0x2568845D, 'data1': 0x2332,
'data2': 0x4675 , 'data3': 0xBC39,
'data4': b'\x8F\xA5\xA4\x74\x8D\x15'
},
'bootl2' : { # Android Bootloader 2
'data0': 0x114EAFFE, 'data1': 0x1552,
'data2': 0x4022 , 'data3': 0xB26E,
'data4': b'\x9B\x05\x36\x04\xCF\x84'
},
'boot' : { # Android Boot
'data0': 0x49A4D17F, 'data1': 0x93A3,
'data2': 0x45C1 , 'data3': 0xA0DE,
'data4': b'\xF5\x0B\x2E\xBE\x25\x99'
},
'recover': { # Android Recovery
'data0': 0x4177C722, 'data1': 0x9E92,
'data2': 0x4AAB , 'data3': 0x8644,
'data4': b'\x43\x50\x2B\xFD\x55\x06'
},
'misc' : { # Android Miscellaneous
'data0': 0xEF32A33B, 'data1': 0xA409,
'data2': 0x486C , 'data3': 0x9141,
'data4': b'\x9F\xFB\x71\x1F\x62\x66'
},
'meta' : { # Android Metadata
'data0': 0x20AC26BE, 'data1': 0x20B7,
'data2': 0x11E3 , 'data3': 0x84C5,
'data4': b'\x6C\xFD\xB9\x47\x11\xE9'
},
'system' : { # Android System
'data0': 0x38F428E6, 'data1': 0xD326,
'data2': 0x425D , 'data3': 0x9140,
'data4': b'\x6E\x0E\xA1\x33\x64\x7C'
},
'cache' : { # Android Cache
'data0': 0xA893EF21, 'data1': 0xE428,
'data2': 0x470A , 'data3': 0x9E55,
'data4': b'\x06\x68\xFD\x91\xA2\xD9'
},
'data' : { # Android Data
'data0': 0xDC76DDA9, 'data1': 0x5AC1,
'data2': 0x491C , 'data3': 0xAF42,
'data4': b'\xA8\x25\x91\x58\x0C\x0D'
},
'persist': { # Android Persistent
'data0': 0xEBC597D0, 'data1': 0x2053,
'data2': 0x4B15 , 'data3': 0x8B64,
'data4': b'\xE0\xAA\xC7\x5F\x4D\xB1'
},
'vendor' : { # Android Vendor
'data0': 0xC5A0AEEC, 'data1': 0x13EA,
'data2': 0x11E5 , 'data3': 0xA1B1,
'data4': b'\x00\x1E\x67\xCA\x0C\x3C'
},
'config' : { # Android Config
'data0': 0xBD59408B, 'data1': 0x4514,
'data2': 0x490D , 'data3': 0xBF12,
'data4': b'\x98\x78\xD9\x63\xF3\x78'
},
'fact' : { # Android Factory
'data0': 0x8F68CC74, 'data1': 0xC5E5,
'data2': 0x48DA , 'data3': 0xBE91,
'data4': b'\xA0\xC8\xC1\x5E\x9C\x80'
},
'factalt': { # Android Factory (alt)
'data0': 0x9FDAA6EF, 'data1': 0x4B3F,
'data2': 0x40D2 , 'data3': 0xBA8D,
'data4': b'\xBF\xF1\x6B\xFB\x88\x7B'
},
'fboot' : { # Android Fastboot / Tertiary
'data0': 0x767941D0, 'data1': 0x2085,
'data2': 0x11E3 , 'data3': 0xAD3B,
'data4': b'\x6C\xFD\xB9\x47\x11\xE9'
},
'oem' : { # Android OEM
'data0': 0xAC6D7924, 'data1': 0xEB71,
'data2': 0x4DF8 , 'data3': 0xB48D,
'data4': b'\xE2\x67\xB2\x71\x48\xFF'
},
}
ANDROID_ARM_PART_TYPES = {
'meta' : { # Android Meta
'data0': 0x19A710A2, 'data1': 0xB3CA,
'data2': 0x11E4 , 'data3': 0xB026,
'data4': b'\x10\x60\x4B\x88\x9D\xCF'
},
'ext' : { # Android EXT
'data0': 0x193D1EA4, 'data1': 0xB3CA,
'data2': 0x11E4 , 'data3': 0xB075,
'data4': b'\x10\x60\x4B\x88\x9D\xCF'
},
}
ONIE_PART_TYPES = {
'boot' : { # Boot
'data0': 0x7412F7D5, 'data1': 0xA156,
'data2': 0x4B13 , 'data3': 0x81DC,
'data4': b'\x86\x71\x74\x92\x93\x25'
},
'config' : { # Config
'data0': 0xD4E6E2CD, 'data1': 0x4469,
'data2': 0x46F3 , 'data3': 0xB5CB,
'data4': b'\x1B\xFF\x57\xAF\xC1\x49'
},
}
POWERPC_PART_TYPES = {
'boot' : { # PReP boot
'data0': 0x9E1A2D38, 'data1': 0xC612,
'data2': 0x4316 , 'data3': 0xAA26,
'data4': b'\x8B\x49\x52\x1E\x5A\x8B'
},
}
FREEDESKTOP_PART_TYPES = {
'boot' : { # Shared boot loader config
'data0': 0xBC13C2FF, 'data1': 0x59E6,
'data2': 0x4262 , 'data3': 0xA352,
'data4': b'\xB2\x75\xFD\x6F\x71\x72'
},
}
ATARI_TOS_PART_TYPES = {
'data' : { # Basic Data Partition (GME, BGM, F32)
'data0': 0x734E5AFE, 'data1': 0xF61A,
'data2': 0x11E6 , 'data3': 0xBC64,
'data4': b'\x92\x36\x1F\x00\x26\x71'
},
}
VERACRYPT_PART_TYPES = {
'data' : { # Encrypted data partition
'data0': 0x8C8F8EFF, 'data1': 0xAC95,
'data2': 0x4770 , 'data3': 0x814A,
'data4': b'\x21\x99\x4F\x2D\xBC\x8F'
},
}
OS2_PART_TYPES = {
'type1' : { # ArcaOS Type 1
'data0': 0x90B6FF38, 'data1': 0xB98F,
'data2': 0x4358 , 'data3': 0xA21F,
'data4': b'\x48\xF3\x5B\x4A\x8A\xD3'
},
}
SPDK_PART_TYPES = {
'block' : { # SPDK Block Device
'data0': 0x7C5222BD, 'data1': 0x8F5D,
'data2': 0x4087 , 'data3': 0x9C00,
'data4': b'\xBF\x98\x43\xC7\xB5\x8C'
},
}
BAREBOX_PART_TYPES = {
'state' : { # barebox-state
'data0': 0x4778ed65, 'data1': 0xbf42,
'data2': 0x45fa , 'data3': 0x9c5b,
'data4': b'\x28\x7a\x1d\xc4\xaa\xb1'
},
}
GPT_PART_TYPES = {
'uefi' : { **UEFI_CORE_PART_TYPES },
'windows' : { **WINDOWS_PART_TYPES },
'hpux' : { **HPUX_PART_TYPES },
'linux' : { **LINUX_PART_TYPES },
'darwin' : { **DARWIN_PART_TYPES },
'solaris' : { **SOLARIS_PART_TYPES },
'netbsd' : { **NETBSD_PART_TYPES },
'chromeos' : { **CHROMEOS_PART_TYPES },
'coreos' : { **COREOS_PART_TYPES },
'haiku' : { **HAIKU_PART_TYPES },
'midnight' : { **MIDNIGHT_PART_TYPES },
'ceph' : { **CEPH_PART_TYPES },
'openbsd' : { **OPENBSD_PART_TYPES },
'qnx' : { **QNX_PART_TYPES },
'plan9' : { **PLAN9_PART_TYPES },
'vmware' : { **VMWARE_PART_TYPES },
'android_ia' : { **ANDROID_IA_PART_TYPES },
'android_arm': { **ANDROID_ARM_PART_TYPES },
'onie' : { **ONIE_PART_TYPES },
'powerpc' : { **POWERPC_PART_TYPES },
'freedesktop': { **FREEDESKTOP_PART_TYPES },
'atari_tos' : { **ATARI_TOS_PART_TYPES },
'veracrypt' : { **VERACRYPT_PART_TYPES },
'os2' : { **OS2_PART_TYPES },
'spdk' : { **SPDK_PART_TYPES },
'barebox' : { **BAREBOX_PART_TYPES },
}
|
def echo(user , lang , sys) :
print('User:', user, 'Language:', lang, 'Platform:', sys)
echo('Mike' , 'Python' , 'Window')
echo(lang = 'Python' , sys = 'Mac OS' , user = 'Anne')
def mirror(user = 'Carole' , lang = 'Python') :
print('\nUser:' , user , 'Language:' , lang)
mirror()
mirror(lang = 'Java')
mirror(user = 'Tony')
mirror('Susan' , 'C++')
|
TOTAL_CHARACTERS = """
SELECT COUNT(name)
FROM charactercreator_character;
"""
TOTAL_SUBCLASS = """
SELECT
(SELECT COUNT(*)
FROM charactercreator_cleric
) as cleric,
(SELECT COUNT(*)
FROM charactercreator_fighter
) AS fighter,
(SELECT COUNT(*)
FROM charactercreator_mage
) AS mage,
(SELECT COUNT(*)
FROM charactercreator_necromancer
) AS necromancer,
(SELECT COUNT(*)
FROM charactercreator_thief
) AS theif;
"""
TOTAL_ITEMS = """
SELECT COUNT(*)
FROM armory_item;
"""
TOTAL_WEPONS = """
SELECT COUNT(*)
FROM armory_weapon;
"""
NON_WEPONS = """
SELECT item_id, item_ptr_id
FROM armory_item
INNER JOIN armory_weapon
ON armory_item.item_id = armory_weapon.item_ptr_id;
"""
CHARACTER_ITEMS = """
SELECT character_id, COUNT(character_id)
FROM charactercreator_character_inventory
GROUP BY character_id;
"""
|
"""
보드 구현 전반에 사용되는 상수 모음.
"""
# Post Activities
ACTIVITY_VIEW = 'VIEW'
ACTIVITY_VOTE = 'VOTE'
# 보드 역할
BOARD_ROLE = {
'DEFAULT': 'DEFAULT',
'PROJECT': 'PROJECT',
'DEBATE': 'DEBATE',
'PLANBOOK': 'PLANBOOK',
'ARCHIVING':'ARCHIVING',
'WORKHOUR': 'WORKHOUR',
'SPONSOR': 'SPONSOR',
'SWIPER':'SWIPER',
'STORE': 'STORE',
'CONTACT':'CONTACT',
}
# 배너 캐러셀 노출위치
BANNER_CAROUSEL_SECTOR = {
'MAIN': 0,
}
# 페이지당 아이탬 수 (per_page)
POST_PER_PAGE = 15
COMMENT_PER_PAGE = 15
|
'''
Задача «Отрицательная степень»
Условие
Дано действительное положительное число a и целоe число n.
Вычислите a^n. Решение оформите в виде функции power(a, n).
Стандартной функцией возведения в степень пользоваться нельзя.
'''
def power(a, n):
res = 1
n1 = abs(n)
if n > 0:
for i in range(1, int(n1) + 1):
res *= a
return res
else:
for i in range(1, int(n1) + 1):
res *= 1 / a
return res
a = float(input())
n = float(input())
print(power(a, n))
# Решение разработчиков
def power(a, n):
res = 1
for i in range(abs(n)):
res *= a
if n >= 0:
return res
else:
return 1 / res
print(power(float(input()), int(input())))
|
numbers = []
while True:
num = input('Enter a number: ')
if num == 'done':
break
try:
num = int(num)
numbers.append(num)
except ValueError:
print('Invalid input')
largest = max(numbers)
smallest = min(numbers)
print(f'Maximum is {largest}')
print(f'Minimum is {smallest}')
|
def reverseLeftWords(s: str, n: int) -> str:
return s[n:] + s[:n]
def reverseLeftWords(s: str, n: int) -> str:
str_list = []
length = len(s)
for i in range(n, n + length):
str_list.append(s[i % length])
return ''.join(str_list)
|
# O(log n)
def recursiveBinarySearch(vector, left_index, right_index, wanted):
if left_index <= right_index:
pivot = round(left_index + (right_index - left_index) / 2)
if (vector[pivot] == wanted): return pivot
elif vector[pivot] < wanted:
return recursiveBinarySearch(vector, pivot+1, right_index, wanted)
else:
return recursiveBinarySearch(vector, left_index, pivot-1, wanted)
else:
return -1
vector = [1, 2, 3, 4, 5, 6]
print(recursiveBinarySearch(vector, 0, len(vector)-1, 5))
|
#!/usr/bin/python3
"""Alta3 Research | RZFeeser
Review of Lists and Dictionaries"""
# define a short data set (in real world, we want to read this from a file or API)
munsters = {'endDate': 1966, 'startDate': 1964,\
'names':['Lily', 'Herman', 'Grandpa', 'Eddie', 'Marilyn']} # {} creates dict
# Your solution goes below this line
# ----------------------------------
# Display the value mapped to names
names = munsters["names"]
for i in range(len(names)):
print(names[i])
# Display the value mapped to endDate
print(munsters["endDate"])
# Display the value mapped to startDate
print(munsters["startDate"])
# Add a new key, episodes mapped to the value of 70
munsters["episodes"] = 70
print(munsters)
|
with open('assets/day09.txt', 'r') as file:
lines = [line for line in file.read().splitlines()]
depths = [[9] + [int(d) for d in line] + [9] for line in lines]
depths = [[9] * len(depths[0])] + depths + [[9] * len(depths[0])]
minimums = []
for y in range(1, len(depths) - 1):
for x in range(1, len(depths[y]) - 1):
depth = depths[y][x]
minimum_depth = min(depths[y - 1][x], depths[y + 1][x], depths[y][x - 1], depths[y][x + 1])
if depth < minimum_depth:
minimums.append(depth)
print(f"Minimum risk level: {sum(minimums) + len(minimums)}")
|
CONTENT = """huc basin
<!--10n 60s-->
01 New England
0101 St. John
010100 St. John
01010001 Upper St. John
01010002 Allagash
01010003 Fish
01010004 Aroostook
01010005 Meduxnekeag
0102 Penobscot
010200 Penobscot
01020001 West Branch Penobscot
01020002 East Branch Penobscot
01020003 Mattawamkeag
01020004 Piscataquis
01020005 Lower Penobscot
0103 Kennebec
010300 Kennebec
01030001 Upper Kennebec
01030002 Dead
01030003 Lower Kennebec
0104 Androscoggin
010400 Androscoggin
01040001 Upper Androscoggin
01040002 Lower Androscoggin
0105 Maine Coastal
010500 Maine Coastal
01050001 St. Croix
01050002 Maine Coastal
01050003 St. George-Sheepscot
0106 Saco
010600 Saco
01060001 Presumpscot
01060002 Saco
01060003 Piscataqua-Salmon Falls
0107 Merrimack
010700 Merrimack
01070001 Pemigewasset
01070002 Merrimack
01070003 Contoocook
01070004 Nashua
01070005 Concord
0108 Connecticut
010801 Upper Connecticut
01080101 Upper Connecticut
01080102 Passumpsic
01080103 Waits
01080104 Upper Connecticut-Mascoma
01080105 White
01080106 Black-Ottauquechee
01080107 West
010802 Lower Connecticut
01080201 Middle Connecticut
01080202 Miller
01080203 Deerfield
01080204 Chicopee
01080205 Lower Connecticut
01080206 Westfield
01080207 Farmington
0109 Massachusetts-Rhode Island Coastal
010900 Massachusetts-Rhode Island Coastal
01090001 Charles
01090002 Cape Cod
01090003 Blackstone
01090004 Narragansett
01090005 Pawcatuck-Wood
0110 Connecticut Coastal
011000 Connecticut Coastal
01100001 Quinebaug
01100002 Shetucket
01100003 Thames
01100004 Quinnipiac
01100005 Housatonic
01100006 Saugatuck
01100007 Long Island Sound
0111 St. Francois
011100 St. Francois
01110000 St. Francois
02 Mid Atlantic
0201 Richelieu
020100 Richelieu
02010001 Lake George
02010002 Otter
02010003 Winooski
02010004 Ausable
02010005 Lamoille
02010006 Great Chazy-Saranac
02010007 Missisquoi
0202 Upper Hudson
020200 Upper Hudson
02020001 Upper Hudson
02020002 Sacandaga
02020003 Hudson-Hoosic
02020004 Mohawk
02020005 Schoharie
02020006 Middle Hudson
02020007 Rondout
02020008 Hudson-Wappinger
0203 Lower Hudson-Long Island
020301 Lower Hudson
02030101 Lower Hudson
02030102 Bronx
02030103 Hackensack-Passaic
02030104 Sandy Hook-Staten Island
02030105 Raritan
020302 Long Island
02030201 Northern Long Island
02030202 Southern Long Island
0204 Delaware
020401 Upper Delaware
02040101 Upper Delaware
02040102 East Branch Delaware
02040103 Lackawaxen
02040104 Middle Delaware-Mongaup-Brodhead
02040105 Middle Delaware-Musconetcong
02040106 Lehigh
020402 Lower Delaware
02040201 Crosswicks-Neshaminy
02040202 Lower Delaware
02040203 Schuylkill
02040204 Delaware Bay
02040205 Brandywine-Christina
02040206 Cohansey-Maurice
02040207 Broadkill-Smyrna
020403 New Jersey Coastal
02040301 Mullica-Toms
02040302 Great Egg Harbor
0205 Susquehanna
020501 Upper Susquehanna
02050101 Upper Susquehanna
02050102 Chenango
02050103 Owego-Wappasening
02050104 Tioga
02050105 Chemung
02050106 Upper Susquehanna-Tunkhannock
02050107 Upper Susquehanna-Lackawanna
020502 West Branch Susquehanna
02050201 Upper West Branch Susquehanna
02050202 Sinnemahoning
02050203 Middle West Branch Susquehanna
02050204 Bald Eagle
02050205 Pine
02050206 Lower West Branch Susquehanna
020503 Lower Susquehanna
02050301 Lower Susquehanna-Penns
02050302 Upper Juniata
02050303 Raystown
02050304 Lower Juniata
02050305 Lower Susquehanna-Swatara
02050306 Lower Susquehanna
0206 Upper Chesapeake
020600 Upper Chesapeake
02060001 Upper Chesapeake Bay
02060002 Chester-Sassafras
02060003 Gunpowder-Patapsco
02060004 Severn
02060005 Choptank
02060006 Patuxent
02060007 Blackwater-Wicomico
02060008 Nanticoke
02060009 Pocomoke
02060010 Chincoteague
0207 Potomac
020700 Potomac
02070001 South Branch Potomac
02070002 North Branch Potomac
02070003 Cacapon-Town
02070004 Conococheague-Opequon
02070005 South Fork Shenandoah
02070006 North Fork Shenandoah
02070007 Shenandoah
02070008 Middle Potomac-Catoctin
02070009 Monocacy
02070010 Middle Potomac-Anacostia-Occoquan
02070011 Lower Potomac
0208 Lower Chesapeake
020801 Lower Chesapeake
02080101 Lower Chesapeake Bay
02080102 Great Wicomico-Piankatank
02080103 Rapidan-Upper Rappahannock
02080104 Lower Rappahannock
02080105 Mattaponi
02080106 Pamunkey
02080107 York
02080108 Lynnhaven-Poquoson
02080109 Western Lower Delmarva
02080110 Eastern Lower Delmarva
020802 James
02080201 Upper James
02080202 Maury
02080203 Middle James-Buffalo
02080204 Rivanna
02080205 Middle James-Willis
02080206 Lower James
02080207 Appomattox
02080208 Hampton Roads
03 South Atlantic-Gulf
0301 Chowan-Roanoke
030101 Roanoke
03010101 Upper Roanoke
03010102 Middle Roanoke
03010103 Upper Dan
03010104 Lower Dan
03010105 Banister
03010106 Roanoke Rapids
03010107 Lower Roanoke
030102 Albemarle-Chowan
03010201 Nottoway
03010202 Blackwater
03010203 Chowan
03010204 Meherrin
03010205 Albemarle
0302 Neuse-Pamlico
030201 Pamlico
03020101 Upper Tar
03020102 Fishing
03020103 Lower Tar
03020104 Pamlico
03020105 Pamlico Sound
03020106 Bogue-Core Sounds
030202 Neuse
03020201 Upper Neuse
03020202 Middle Neuse
03020203 Contentnea
03020204 Lower Neuse
0303 Cape Fear
030300 Cape Fear
03030001 New
03030002 Haw
03030003 Deep
03030004 Upper Cape Fear
03030005 Lower Cape Fear
03030006 Black
03030007 Northeast Cape Fear
0304 Pee Dee
030401 Upper Pee Dee
03040101 Upper Yadkin
03040102 South Yadkin
03040103 Lower Yadkin
03040104 Upper Pee Dee
03040105 Rocky
030402 Lower Pee Dee
03040201 Lower Pee Dee
03040202 Lynches
03040203 Lumber
03040204 Little Pee Dee
03040205 Black
03040206 Waccamaw
03040207 Carolina Coastal-Sampit
0305 Edisto-Santee
030501 Santee
03050101 Upper Catawba
03050102 South Fork Catawba
03050103 Lower Catawba
03050104 Wateree
03050105 Upper Broad
03050106 Lower Broad
03050107 Tyger
03050108 Enoree
03050109 Saluda
03050110 Congaree
03050111 Lake Marion
03050112 Santee
030502 Edisto-South Carolina Coastal
03050201 Cooper
03050202 South Carolina Coastal
03050203 North Fork Edisto
03050204 South Fork Edisto
03050205 Edisto
03050206 Four Hole Swamp
03050207 Salkehatchie
03050208 Broad-St. Helena
0306 Ogeechee-Savannah
030601 Savannah
03060101 Seneca
03060102 Tugaloo
03060103 Upper Savannah
03060104 Broad
03060105 Little
03060106 Middle Savannah
03060107 Stevens
03060108 Brier
03060109 Lower Savannah
030602 Ogeechee
03060201 Upper Ogeechee
03060202 Lower Ogeechee
03060203 Canoochee
03060204 Ogeechee Coastal
0307 Altamaha - St. Marys
030701 Altamaha
03070101 Upper Oconee
03070102 Lower Oconee
03070103 Upper Ocmulgee
03070104 Lower Ocmulgee
03070105 Little Ocmulgee
03070106 Altamaha
03070107 Ohoopee
030702 St. Marys - Satilla
03070201 Satilla
03070202 Little Satilla
03070203 Cumberland-St. Simons
03070204 St. Marys
03070205 Nassau
0308 St. Johns
030801 St. Johns
03080101 Upper St. Johns
03080102 Oklawaha
03080103 Lower St. Johns
030802 East Florida Coastal
03080201 Daytona - St. Augustine
03080202 Cape Canaveral
03080203 Vero Beach
0309 Southern Florida
030901 Kissimmee
03090101 Kissimmee
03090102 Northern Okeechobee Inflow
03090103 Western Okeechobee Inflow
030902 Southern Florida
03090201 Lake Okeechobee
03090202 Everglades
03090203 Florida Bay-Florida Keys
03090204 Big Cypress Swamp
03090205 Caloosahatchee
0310 Peace-Tampa Bay
031001 Peace
03100101 Peace
03100102 Myakka
03100103 Charlotte Harbor
031002 Tampa Bay
03100201 Sarasota Bay
03100202 Manatee
03100203 Little Manatee
03100204 Alafia
03100205 Hillsborough
03100206 Tampa Bay
03100207 Crystal-Pithlachascotee
03100208 Withlacoochee
0311 Suwannee
031101 Aucilla-Waccasassa
03110101 Waccasassa
03110102 Econfina-Steinhatchee
03110103 Aucilla
031102 Suwannee
03110201 Upper Suwannee
03110202 Alapaha
03110203 withlacoochee
03110204 Little
03110205 Lower Suwannee
03110206 Santa Fe
0312 Ochlockonee
031200 Ochlockonee. Georgia
03120001 Apalachee Bay-St. Marks
03120002 Upper Ochlockonee
03120003 Lower Ochlockonee
0313 Apalachicola
031300 Apalachicola
03130001 Upper Chattahoochee
03130002 Middle Chattahoochee-Lake Harding
03130003 Middle Chattahoochee-Walter F. George Reservoir
03130004 Lower Chattahoochee
03130005 Upper Flint
03130006 Middle Flint
03130007 Kinchafoonee-Muckalee
03130008 Lower Flint
03130009 Ichawaynochaway
03130010 Spring
03130011 Apalachicola
03130012 Chipola
03130013 New
03130014 Apalachicola Bay
0314 Choctawhatchee - Escambia
031401 Florida Panhandle Coastal
03140101 St. Andrew-St. Joseph Bays
03140102 Choctawhatchee Bay
03140103 Yellow
03140104 Blackwater
03140105 Pensacola Bay
03140106 Perdido
03140107 Perdido Bay
031402 Choctawhatchee
03140201 Upper Choctawhatchee
03140202 Pea
03140203 Lower Choctawhatchee
031403 Escambia
03140301 Upper Conecuh
03140302 Patsaliga
03140303 Sepulga
03140304 Lower Conecuh
03140305 Escambia
0315 Alabama
031501 Coosa-Tallapoosa
03150101 Conasauga
03150102 Coosawattee
03150103 Oostanaula
03150104 Etowah
03150105 Upper Coosa
03150106 Middle Coosa
03150107 Lower Coosa
03150108 Upper Tallapoosa
03150109 Middle Tallapoosa
03150110 Lower Tallapoosa
031502 Alabama
03150201 Upper Alabama
03150202 Cahaba
03150203 Middle Alabama
03150204 Lower Alabama
0316 Mobile - Tombigbee
031601 Black Warrior - Tombigbee
03160101 Upper Tombigbee
03160102 Town
03160103 Buttahatchee
03160104 Tibbee
03160105 Luxapallila
03160106 Middle Tombigbee-Lubbub
03160107 Sipsey
03160108 Noxubee
03160109 Mulberry
03160110 Sipsey Fork
03160111 Locust
03160112 Upper Black Warrior
03160113 Lower Black Warrior
031602 Mobile Bay- Tombigbee
03160201 Middle Tombigbee-Chickasaw
03160202 Sucarnoochee
03160203 Lower Tambigbee
03160204 Mobile - Tensaw
03160205 Mobile Bay
0317 Pascagoula
031700 Pascagoula. Mississippi
03170001 Chunky-Okatibbee
03170002 Upper Chickasawhay
03170003 Lower Chickasawhay
03170004 Upper Leaf
03170005 Lower Leaf
03170006 Pascagoula
03170007 Black
03170008 Escatawpa
03170009 Mississippi Coastal
0318 Pearl
031800 Pearl
03180001 Upper Pearl
03180002 Middle Pearl-Strong
03180003 Middle Pearl-Silver
03180004 Lower Pearl. Mississippi
03180005 Bogue Chitto
04 Great Lakes
0401 Western Lake Superior
040101 Northwestern Lake Superior
04010101 Baptism-Brule
04010102 Beaver-Lester
040102 St. Louis
04010201 St. Louis
04010202 Cloquet
040103 Southwestern Lake Superior
04010301 Beartrap-Nemadji
04010302 Bad-Montreal
0402 Southern Lake Superior-Lake Superior
040201 Southcentral Lake Superior
04020101 Black-Presque Isle
04020102 Ontonagon
04020103 Keweenaw Peninsula
04020104 Sturgeon
04020105 Dead-Kelsey
040202 Southeastern Lake Superior
04020201 Betsy-Chocolay
04020202 Tahquamenon
04020203 Waiska
040203 Lake Superior
04020300 Lake Superior
0403 Northwestern Lake Michigan
040301 Northwestern Lake Michigan
04030101 Manitowoc-Sheboygan
04030102 Door-Kewaunee
04030103 Duck-Pensaukee
04030104 Oconto
04030105 Peshtigo
04030106 Brule
04030107 Michigamme
04030108 Menominee
04030109 Cedar-Ford
04030110 Escanaba
04030111 Tacoosh-Whitefish
04030112 Fishdam-Sturgeon
040302 Fox
04030201 Upper Fox
04030202 Wolf
04030203 Lake Winnebago
04030204 Lower Fox
0404 Southwestern Lake Michigan
040400 Southwestern Lake Michigan
04040001 Little Calumet-Galien
04040002 Pike-Root
04040003 Milwaukee
0405 Southeastern Lake Michigan
040500 Southeastern Lake Michigan
04050001 St. Joseph
04050002 Black-Macatawa
04050003 Kalamazoo
04050004 Upper Grand
04050005 Maple
04050006 Lower Grand
04050007 Thornapple
0406 Northeastern Lake Michigan-Lake Michigan
040601 Northeastern Lake Michigan
04060101 Pere Marquette-White
04060102 Muskegon
04060103 Manistee
04060104 Betsie-Platte
04060105 Boardman-Charlevoix
04060106 Manistique
04060107 Brevoort-Millecoquins
040602 Lake Michigan
04060200 Lake Michigan
0407 Northwestern Lake Huron
040700 Northwestern Lake Huron
04070001 St. Marys
04070002 Carp-Pine
04070003 Lone Lake-Ocqueoc
04070004 Cheboygan
04070005 Black
04070006 Thunder Bay
04070007 Au Sable
0408 Southwestern Lake Huron-Lake Huron
040801 Southwestern Lake Huron
04080101 Au Gres-Rifle
04080102 Kawkawlin-Pine
04080103 Pigeon-Wiscoggin
04080104 Birch-Willow
040802 Saginaw
04080201 Tittabawassee
04080202 Pine
04080203 Shiawassee
04080204 Flint
04080205 Cass
04080206 Saginaw
040803 Lake Huron
04080300 Lake Huron
0409 St. Clair-Detroit
040900 St. Clair-Detroit
04090001 St. Clair
04090002 Lake St. Clair
04090003 Clinton
04090004 Detroit
04090005 Huron
0410 Western Lake Erie
041000 Western Lake Erie
04100001 Ottawa-Stony
04100002 Raisin
04100003 St. Joseph
04100004 St. Marys
04100005 Upper Maumee
04100006 Tiffin
04100007 Auglaize
04100008 Blanchard
04100009 Lower Maumee
04100010 Cedar-Portage
04100011 Sandusky
04100012 Huron-Vermilion
0411 Southern Lake Erie
041100 Southern Lake Erie
04110001 Black-Rocky
04110002 Cuyahoga
04110003 Ashtabula-Chagrin
04110004 Grand
0412 Eastern Lake Erie-Lake Erie
041201 Eastern Lake Erie
04120101 Chautauqua-Conneaut
04120102 Cattaraugus
04120103 Buffalo-Eighteenmile
04120104 Niagara
041202 Lake Erie
04120200 Lake Erie
0413 Southwestern Lake Ontario
041300 Southwestern Lake Ontario
04130001 Oak Orchard-Twelvemile
04130002 Upper Genesee
04130003 Lower Genesee
0414 Southeastern Lake Ontario
041401 Southeastern Lake Ontario
04140101 Irondequoit-Ninemile
04140102 Salmon-Sandy
041402 Oswego
04140201 Seneca
04140202 Oneida
04140203 Oswego
0415 Northeastern Lake Ontario-Lake Ontario-St. Lawrence
041501 Northeastern Lake Ontario
04150101 Black
04150102 Chaumont-Perch
041502 Lake Ontario
04150200 Lake Ontario
041503 St. Lawrence
04150301 Upper St. Lawrence
04150302 Oswegatchie
04150303 Indian
04150304 Grass
04150305 Raquette
04150306 St. Regis
04150307 English-Salmon
05 Ohio
0501 Allegheny
050100 Allegheny
05010001 Upper Allegheny
05010002 Conewango
05010003 Middle Allegheny-Tionesta
05010004 French
05010005 Clarion
05010006 Middle Allegheny-Redbank
05010007 Conemaugh
05010008 Kiskiminetas
05010009 Lower Allegheny
0502 Monongahela
050200 Monongahela
05020001 Tygart Valley
05020002 West Fork
05020003 Upper Monongahela
05020004 Cheat
05020005 Lower Monongahela
05020006 Youghiogheny
0503 Upper Ohio
050301 Upper Ohio-Beaver
05030101 Upper Ohio
05030102 Shenango
05030103 Mahoning
05030104 Beaver
05030105 Connoquenessing
05030106 Upper Ohio-Wheeling
050302 Upper Ohio-Little Kanawha
05030201 Little Muskingum-Middle Island
05030202 Upper Ohio-Shade
05030203 Little Kanawha
05030204 Hocking
0504 Muskingum
050400 Muskingum
05040001 Tuscarawas
05040002 Mohican
05040003 Walhonding
05040004 Muskingum
05040005 Wills
05040006 Licking
0505 Kanawha
050500 Kanawha
05050001 Upper New
05050002 Middle New
05050003 Greenbrier
05050004 Lower New
05050005 Gauley
05050006 Upper Kanawha
05050007 Elk
05050008 Lower Kanawha
05050009 Coal
0506 Scioto
050600 Scioto
05060001 Upper Scioto
05060002 Lower Scioto
05060003 Paint
0507 Big Sandy-Guyandotte
050701 Guyandotte
05070101 Upper Guyandotte
05070102 Lower Guyandotte
050702 Big Sandy
05070201 Tug
05070202 Upper Levisa
05070203 Lower Levisa
05070204 Big Sandy
0508 Great Miami
050800 Great Miami
05080001 Upper Great Miami
05080002 Lower Great Miami
05080003 Whitewater
0509 Middle Ohio
050901 Middle Ohio-Raccoon
05090101 Raccoon-Symmes
05090102 Twelvepole
05090103 Little Scioto-Tygarts
05090104 Little Sandy
050902 Middle Ohio-Little Miami
05090201 Ohio Brush-Whiteoak
05090202 Little Miami
05090203 Middle Ohio-Laughery
0510 Kentucky-Licking
051001 Licking
05100101 Licking
05100102 South Fork Licking
051002 Kentucky
05100201 North Fork Kentucky
05100202 Middle Fork Kentucky
05100203 South Fork Kentucky
05100204 Upper Kentucky
05100205 Lower Kentucky
0511 Green
051100 Green
05110001 Upper Green
05110002 Barren
05110003 Middle Green
05110004 Rough
05110005 Lower Green
05110006 Pond
0512 Wabash
051201 Wabash
05120101 Upper Wabash
05120102 Salamonie
05120103 Mississinewa
05120104 Eel
05120105 Middle Wabash-Deer
05120106 Tippecanoe
05120107 Wildcat
05120108 Middle Wabash-Little Vermilion
05120109 Vermilion
05120110 Sugar
05120111 Middle Wabash-Busseron
05120112 Embarras
05120113 Lower Wabash
05120114 Little Wabash
05120115 Skillet
051202 Patoka-White
05120201 Upper White
05120202 Lower White
05120203 Eel
05120204 Driftwood
05120205 Flatrock-Haw
05120206 Upper East Fork White
05120207 Muscatatuck
05120208 Lower East Fork White
05120209 Patoka
0513 Cumberland
051301 Upper Cumberland
05130101 Upper Cumberland
05130102 Rockcastle
05130103 Upper Cumberland-Lake Cumberland
05130104 South Fork Cumberland
05130105 Obey
05130106 Upper Cumberland-Cordell Hull
05130107 Collins
05130108 Caney
051302 Lower Cumberland
05130201 Lower Cumberland-Old Hickory Lake
05130202 Lower Cumberland-Sycamore
05130203 Stones
05130204 Harpeth
05130205 Lower Cumberland
05130206 Red
0514 Lower Ohio
051401 Lower Ohio-Salt
05140101 Silver-Little Kentucky
05140102 Salt
05140103 Rolling Fork
05140104 Blue-Sinking
051402 Lower Ohio
05140201 Lower Ohio-Little Pigeon
05140202 Highland-Pigeon
05140203 Lower Ohio-Bay
05140204 Saline
05140205 Tradewater
05140206 Lower Ohio
06 Tennessee
0601 Upper Tennessee
060101 French Broad-Holston
06010101 North Fork Holston
06010102 South Fork Holston
06010103 Watauga
06010104 Holston
06010105 Upper French Broad
06010106 Pigeon
06010107 Lower French Broad
06010108 Nolichucky
060102 Upper Tennessee
06010201 Watts Bar Lake
06010202 Upper Little Tennessee
06010203 Tuckasegee
06010204 Lower Little Tennessee
06010205 Upper Clinch
06010206 Powell
06010207 Lower Clinch
06010208 Emory
0602 Middle Tennessee-Hiwassee
060200 Middle Tennessee-Hiwassee
06020001 Middle Tennessee-Chickamauga
06020002 Hiwassee
06020003 Ocoee
06020004 Sequatchie
0603 Middle Tennessee-Elk
060300 Middle Tennessee-Elk
06030001 Guntersville Lake
06030002 Wheeler Lake
06030003 Upper Elk
06030004 Lower Elk
06030005 Pickwick Lake
06030006 Bear
0604 Lower Tennessee
060400 Lower Tennessee
06040001 Lower Tennessee-Beech
06040002 Upper Duck
06040003 Lower Duck
06040004 Buffalo
06040005 Kentucky Lake
06040006 Lower Tennessee
07 Upper Mississippi
0701 Mississippi Headwaters
070101 Mississippi Headwaters
07010101 Mississippi Headwaters
07010102 Leech Lake
07010103 Prairie-Willow
07010104 Elk-Nokasippi
07010105 Pine
07010106 Crow Wing
07010107 Redeye
07010108 Long Prairie
070102 Upper Mississippi-Crow-Rum
07010201 Platte-Spunk
07010202 Sauk
07010203 Clearwater-Elk
07010204 Crow
07010205 South Fork Crow
07010206 Twin Cities
07010207 Rum
0702 Minnesota
070200 Minnesota
07020001 Upper Minnesota
07020002 Pomme De Terre
07020003 Lac Qui Parle
07020004 Hawk-Yellow Medicine
07020005 Chippewa
07020006 Redwood
07020007 Middle Minnesota
07020008 Cottonwood
07020009 Blue Earth
07020010 Watonwan
07020011 Le Sueur
07020012 Lower Minnesota
0703 St. Croix
070300 St. Croix
07030001 Upper St. Croix
07030002 Namekagon
07030003 Kettle
07030004 Snake
07030005 Lower St. Croix
0704 Upper Mississippi-Black-Root
070400 Upper Mississippi-Black-Root
07040001 Rush-Vermillion
07040002 Cannon
07040003 Buffalo-Whitewater
07040004 Zumbro
07040005 Trempealeau
07040006 La Crosse-Pine
07040007 Black
07040008 Root
0705 Chippewa
070500 Chippewa
07050001 Upper Chippewa
07050002 Flambeau
07050003 South Fork Flambeau
07050004 Jump
07050005 Lower Chippewa
07050006 Eau Claire
07050007 Red Cedar
0706 Upper Mississippi-Maquoketa-Plum
070600 Upper Mississippi-Maquoketa-Plum
07060001 Coon-Yellow
07060002 Upper Iowa
07060003 Grant-Little Maquoketa
07060004 Turkey
07060005 Apple-Plum
07060006 Maquoketa
0707 Wisconsin
070700 Wisconsin
07070001 Upper Wisconsin
07070002 Lake Dubay
07070003 Castle Rock
07070004 Baraboo
07070005 Lower Wisconsin
07070006 Kickapoo
0708 Upper Mississippi-Iowa-Skunk-Wapsipinicon
070801 Upper Mississippi-Skunk-Wapsipinicon
07080101 Copperas-Duck
07080102 Upper Wapsipinicon
07080103 Lower Wapsipinicon
07080104 Flint-Henderson
07080105 South Skunk
07080106 North Skunk
07080107 Skunk
070802 Iowa
07080201 Upper Cedar
07080202 Shell Rock
07080203 Winnebago
07080204 West Fork Cedar
07080205 Middle Cedar
07080206 Lower Cedar
07080207 Upper Iowa
07080208 Middle Iowa
07080209 Lower Iowa
0709 Rock
070900 Rock
07090001 Upper Rock
07090002 Crawfish
07090003 Pecatonica
07090004 Sugar
07090005 Lower Rock
07090006 Kishwaukee
07090007 Green
0710 Des Moines
071000 Des Moines
07100001 Des Moines Headwaters
07100002 Upper Des Moines
07100003 East Fork Des Moines
07100004 Middle Des Moines
07100005 Boone
07100006 North Raccoon
07100007 South Raccoon
07100008 Lake Red Rock
07100009 Lower Des Moines
0711 Upper Mississippi-Salt
071100 Upper Mississippi-Salt
07110001 Bear-Wyaconda
07110002 North Fabius
07110003 South Fabius
07110004 The Sny
07110005 North Fork Salt
07110006 South Fork Salt
07110007 Salt
07110008 Cuivre
07110009 Peruque-Piasa
0712 Upper Illinois
071200 Upper Illinois
07120001 Kankakee
07120002 Iroquois
07120003 Chicago
07120004 Des Plaines
07120005 Upper Illinois
07120006 Upper Fox
07120007 Lower Fox
0713 Lower Illinois
071300 Lower Illinois
07130001 Lower Illinois-Senachwine Lake
07130002 Vermilion
07130003 Lower Illinois-Lake Chautauqua
07130004 Mackinaw
07130005 Spoon
07130006 Upper Sangamon
07130007 South Fork Sangamon
07130008 Lower Sangamon
07130009 Salt
07130010 La Moine
07130011 Lower Illinois
07130012 Macoupin
0714 Upper Mississippi-Kaskaskia-Meramec
071401 Upper Mississippi-Meramec
07140101 Cahokia-Joachim
07140102 Meramec
07140103 Bourbeuse
07140104 Big
07140105 Upper Mississippi-Cape Girardeau
07140106 Big Muddy
07140107 Whitewater
07140108 Cache
071402 Kaskaskia
07140201 Upper Kaskaskia
07140202 Middle Kaskaskia
07140203 Shoal
07140204 Lower Kaskaskia
08 Lower Mississippi
0801 Lower Mississippi-Hatchie
080101 Lower Mississippi-Memphis
08010100 Lower Mississippi-Memphis
080102 Hatchie-Obion
08010201 Bayou De Chien-Mayfield
08010202 Obion
08010203 South Fork Obion
08010204 North Fork Forked Deer
08010205 South Fork Forked Deer
08010206 Forked Deer
08010207 Upper Hatchie
08010208 Lower Hatchie
08010209 Loosahatchie
08010210 Wolf
08010211 Horn Lake-Nonconnah
0802 Lower Mississippi - St. Francis
080201 Lower Mississippi-Helena
08020100 Lower Mississippi-Helena
080202 St. Francis
08020201 New Madrid-St. Johns
08020202 Upper St. Francis
08020203 Lower St. Francis
08020204 Little River Ditches
08020205 L'anguille
080203 Lower White
08020301 Lower White-Bayou Des Arc
08020302 Cache
08020303 Lower White
08020304 Big
080204 Lower Arkansas
08020401 Lower Arkansas
08020402 Bayou Meto
0803 Lower Mississippi - Yazoo
080301 Lower Mississippi-Greenville
08030100 Lower Mississippi-Greenville
080302 Yazoo
08030201 Little Tallahatchie
08030202 Tallahatchie
08030203 Yocona
08030204 Coldwater
08030205 Yalobusha
08030206 Upper Yazoo
08030207 Big Sunflower
08030208 Lower Yazoo
08030209 Deer-Steele
0804 Lower Red - Ouachita
080401 Upper Ouachita
08040101 Ouachita Headwaters
08040102 Upper Ouachita
08040103 Little Missouri
080402 Lower Ouachita
08040201 Lower Ouachita-Smackover
08040202 Lower Ouachita-Bayou De Loutre
08040203 Upper Saline
08040204 Lower Saline
08040205 Bayou Bartholomew
08040206 Bayou D'arbonne
08040207 Lower Ouachita
080403 Lower Red
08040301 Lower Red
08040302 Castor
08040303 Dugdemona
08040304 Little
08040305 Black
08040306 Bayou Cocodrie
0805 Boeuf-Tensas
080500 Boeuf-Tensas
08050001 Boeuf
08050002 Bayou Macon
08050003 Tensas
0806 Lower Mississippi - Big Black
080601 Lower Mississippi-Natchez
08060100 Lower Mississippi-Natchez
080602 Big Black - Homochitto
08060201 Upper Big Black
08060202 Lower Big Black
08060203 Bayou Pierre
08060204 Coles Creek
08060205 Homochitto
08060206 Buffalo
0807 Lower Mississippi-Lake Maurepas
080701 Lower Mississippi-Baton Rouge
08070100 Lower Mississippi-Baton Rouge
080702 Lake Maurepas
08070201 Bayou Sara-Thompson
08070202 Amite
08070203 Tickfaw
08070204 Lake Maurepas
08070205 Tangipahoa
080703 Lower Grand
08070300 Lower Grand
0808 Louisiana Coastal
080801 Atchafalaya - Vermilion
08080101 Atchafalaya
08080102 Bayou Teche
08080103 Vermilion
080802 Calcasieu - Mermentau
08080201 Mermentau Headwaters
08080202 Mermentau
08080203 Upper Calcasieu
08080204 Whisky Chitto
08080205 West Fork Calcasieu
08080206 Lower Calcasieu
0809 Lower Mississippi
080901 Lower Mississippi-New Orleans
08090100 Lower Mississippi-New Orleans
080902 Lake Pontchartrain
08090201 Liberty Bayou-Tchefuncta
08090202 Lake Pontchartrain
08090203 Eastern Louisiana Coastal
080903 Central Louisiana Coastal
08090301 East Central Louisiana Coastal
08090302 West Central Louisiana Coastal
09 Souris-Red-Rainy
0901 Souris
090100 Souris
09010001 Upper Souris
09010002 Des Lacs
09010003 Lower Souris
09010004 Willow
09010005 Deep
0902 Red
090201 Upper Red
09020101 Bois De Sioux
09020102 Mustinka
09020103 Otter Tail
09020104 Upper Red
09020105 Western Wild Rice
09020106 Buffalo
09020107 Elm-Marsh
09020108 Eastern Wild Rice
09020109 Goose
090202 Devils Lake-Sheyenne
09020201 Devils Lake
09020202 Upper Sheyenne
09020203 Middle Sheyenne
09020204 Lower Sheyenne
09020205 Maple
090203 Lower Red
09020301 Sandhill-Wilson
09020302 Red Lakes
09020303 Red Lake
09020304 Thief
09020305 Clearwater
09020306 Grand Marais-Red
09020307 Turtle
09020308 Forest
09020309 Snake
09020310 Park
09020311 Lower Red
09020312 Two Rivers
09020313 Pembina
09020314 Roseau
0903 Rainy
090300 Rainy
09030001 Rainy Headwaters
09030002 Vermilion
09030003 Rainy Lake
09030004 Upper Rainy
09030005 Little Fork
09030006 Big Fork
09030007 Rapid
09030008 Lower Rainy
09030009 Lake of the Woods
10 Missouri
1001 Saskatchewan
100100 Saskatchewan
10010001 Belly
10010002 St. Mary
1002 Missouri Headwaters
100200 Missouri Headwaters
10020001 Red Rock
10020002 Beaverhead
10020003 Ruby
10020004 Big Hole
10020005 Jefferson
10020006 Boulder
10020007 Madison
10020008 Gallatin
1003 Missouri-Marias
100301 Upper Missouri
10030101 Upper Missouri
10030102 Upper Missouri-Dearborn
10030103 Smith
10030104 Sun
10030105 Belt
100302 Marias
10030201 Two Medicine
10030202 Cut Bank
10030203 Marias
10030204 Willow
10030205 Teton
1004 Missouri-Musselshell
100401 Fort Peck Lake
10040101 Bullwhacker-Dog
10040102 Arrow
10040103 Judith
10040104 Fort Peck Reservoir
10040105 Big Dry
10040106 Little Dry
100402 Musselshell
10040201 Upper Musselshell
10040202 Middle Musselshell
10040203 Flatwillow
10040204 Box Elder
10040205 Lower Musselshell
1005 Milk
100500 Milk
10050001 Milk Headwaters
10050002 Upper Milk
10050003 Wild Horse Lake
10050004 Middle Milk
10050005 Big Sandy
10050006 Sage
10050007 Lodge
10050008 Battle
10050009 Peoples
10050010 Cottonwood
10050011 Whitewater
10050012 Lower Milk
10050013 Frenchman
10050014 Beaver
10050015 Rock
10050016 Porcupine
1006 Missouri-Poplar
100600 Missouri-Poplar
10060001 Prarie Elk-Wolf
10060002 Redwater
10060003 Poplar
10060004 West Fork Poplar
10060005 Charlie-Little Muddy
10060006 Big Muddy
10060007 Brush Lake closed basin
1007 Upper Yellowstone
100700 Upper Yellowstone
10070001 Yellowstone Headwaters
10070002 Upper Yellowstone
10070003 Shields
10070004 Upper Yellowstone-Lake Basin
10070005 Stillwater
10070006 Clarks Fork Yellowstone
10070007 Upper Yellowstone-Pompeys Pillar
10070008 Pryor
1008 Big Horn
100800 Big Horn
10080001 Upper Wind
10080002 Little Wind
10080003 Popo Agie
10080004 Muskrat
10080005 Lower Wind
10080006 Badwater
10080007 Upper Bighorn
10080008 Nowood
10080009 Greybull
10080010 Big Horn Lake
10080011 Dry
10080012 North Fork Shoshone
10080013 South Fork Shoshone
10080014 Shoshone
10080015 Lower Bighorn
10080016 Little Bighorn
1009 Powder-Tongue
100901 Tongue
10090101 Upper Tongue
10090102 Lower Tongue
100902 Powder
10090201 Middle Fork Powder
10090202 Upper Powder
10090203 South Fork Powder
10090204 Salt
10090205 Crazy Woman
10090206 Clear
10090207 Middle Powder
10090208 Little Powder
10090209 Lower Powder
10090210 Mizpah
1010 Lower Yellowstone
101000 Lower Yellowstone
10100001 Lower Yellowstone-Sunday
10100002 Big Porcupine
10100003 Rosebud
10100004 Lower Yellowstone
10100005 O'fallon
1011 Missouri-Little Missouri
101101 Lake Sakakawea
10110101 Lake Sakakawea
10110102 Little Muddy
101102 Little Missouri
10110201 Upper Little Missouri
10110202 Boxelder
10110203 Middle Little Missouri
10110204 Beaver
10110205 Lower Little Missouri
1012 Cheyenne
101201 Cheyenne
10120101 Antelope
10120102 Dry Fork Cheyenne
10120103 Upper Cheyenne
10120104 Lance
10120105 Lightning
10120106 Angostura Reservoir
10120107 Beaver
10120108 Hat
10120109 Middle Cheyenne-Spring
10120110 Rapid
10120111 Middle Cheyenne-Elk
10120112 Lower Cheyenne
10120113 Cherry
101202 Belle Fourche
10120201 Upper Belle Fourche
10120202 Lower Belle Fourche
10120203 Redwater
1013 Missouri-Oahe
101301 Lake Oahe
10130101 Painted Woods-Square Butte
10130102 Upper Lake Oahe
10130103 Apple
10130104 Beaver
10130105 Lower Lake Oahe
10130106 West Missouri Coteau
101302 Cannonball-Heart-Knife
10130201 Knife
10130202 Upper Heart
10130203 Lower Heart
10130204 Upper Cannonball
10130205 Cedar
10130206 Lower Cannonball
101303 Grand-Moreau
10130301 North Fork Grand
10130302 South Fork Grand
10130303 Grand
10130304 South Fork Moreau
10130305 Upper Moreau
10130306 Lower Moreau
1014 Missouri-White
101401 Fort Randall Reservoir
10140101 Fort Randall Reservoir
10140102 Bad
10140103 Medicine Knoll
10140104 Medicine
10140105 Crow
101402 White
10140201 Upper White
10140202 Middle White
10140203 Little White
10140204 Lower White
1015 Niobrara
101500 Niobrara
10150001 Ponca
10150002 Niobrara Headwaters
10150003 Upper Niobrara
10150004 Middle Niobrara
10150005 Snake
10150006 Keya Paha
10150007 Lower Niobrara
1016 James
101600 James
10160001 James Headwaters
10160002 Pipestem
10160003 Upper James
10160004 Elm
10160005 Mud
10160006 Middle James
10160007 East Missouri Coteau
10160008 Snake
10160009 Turtle
10160010 North Big Sioux Coteau
10160011 Lower James
1017 Missouri-Big Sioux
101701 Lewis and Clark Lake
10170101 Lewis and Clark Lake
10170102 Vermillion
10170103 South Big Sioux Coteau
101702 Big Sioux
10170201 Middle Big Sioux Coteau
10170202 Upper Big Sioux
10170203 Lower Big Sioux
10170204 Rock
1018 North Platte
101800 North Platte
10180001 North Platte Headwaters
10180002 Upper North Platte
10180003 Pathfinder-Seminoe Reservoirs
10180004 Medicine Bow
10180005 Little Medicine Bow
10180006 Sweetwater
10180007 Middle North Platte-Casper
10180008 Glendo Reservoir
10180009 Middle North Platte-Scotts Bluff
10180010 Upper Laramie
10180011 Lower Laramie
10180012 Horse
10180013 Pumpkin
10180014 Lower North Platte
1019 South Platte
101900 South Platte
10190001 South Platte Headwaters
10190002 Upper South Platte
10190003 Middle South Platte-Cherry Creek
10190004 Clear
10190005 St. Vrain
10190006 Big Thompson
10190007 Cache La Poudre
10190008 Lone Tree-Owl
10190009 Crow
10190010 Kiowa
10190011 Bijou
10190012 Middle South Platte-Sterling
10190013 Beaver
10190014 Pawnee
10190015 Upper Lodgepole
10190016 Lower Lodgepole
10190017 Sidney Draw
10190018 Lower South Platte
1020 Platte
102001 Middle Platte
10200101 Middle Platte-Buffalo
10200102 Wood
10200103 Middle Platte-Prairie
102002 Lower Platte
10200201 Lower Platte-Shell
10200202 Lower Platte
10200203 Salt
1021 Loup
102100 Loup
10210001 Upper Middle Loup
10210002 Dismal
10210003 Lower Middle Loup
10210004 South Loup
10210005 Mud
10210006 Upper North Loup
10210007 Lower North Loup
10210008 Calamus
10210009 Loup
10210010 Cedar
1022 Elkhorn
102200 Elkhorn
10220001 Upper Elkhorn
10220002 North Fork Elkhorn
10220003 Lower Elkhorn
10220004 Logan
1023 Missouri-Little Sioux
102300 Missouri-Little Sioux
10230001 Blackbird-Soldier
10230002 Floyd
10230003 Little Sioux
10230004 Monona-Harrison Ditch
10230005 Maple
10230006 Big Papillion-Mosquito
10230007 Boyer
1024 Missouri-Nishnabotna
102400 Missouri-Nishnabotna
10240001 Keg-Weeping Water
10240002 West Nishnabotna
10240003 East Nishnabotna
10240004 Nishnabotna
10240005 Tarkio-Wolf
10240006 Little Nemaha
10240007 South Fork Big Nemaha
10240008 Big Nemaha
10240009 West Nodaway
10240010 Nodaway
10240011 Independence-Sugar
10240012 Platte
10240013 One Hundred and Two
1025 Republican
102500 Republican
10250001 Arikaree
10250002 North Fork Republican
10250003 South Fork Republican
10250004 Upper Republican
10250005 Frenchman
10250006 Stinking Water
10250007 Red Willow
10250008 Medicine
10250009 Harlan County Reservoir
10250010 Upper Sappa
10250011 Lower Sappa
10250012 South Fork Beaver
10250013 Little Beaver
10250014 Beaver
10250015 Prairie Dog
10250016 Middle Republican
10250017 Lower Republican
1026 Smoky Hill
102600 Smoky Hill
10260001 Smoky Hill Headwaters
10260002 North Fork Smoky Hill
10260003 Upper Smoky Hill
10260004 Ladder
10260005 Hackberry
10260006 Middle Smoky Hill
10260007 Big
10260008 Lower Smoky Hill
10260009 Upper Saline
10260010 Lower Saline
10260011 Upper North Fork Solomon
10260012 Lower North Fork Solomon
10260013 Upper South Fork Solomon
10260014 Lower South Fork Solomon
10260015 Solomon
1027 Kansas
102701 Kansas
10270101 Upper Kansas
10270102 Middle Kansas
10270103 Delaware
10270104 Lower Kansas
102702 Big Blue
10270201 Upper Big Blue
10270202 Middle Big Blue
10270203 West Fork Big Blue
10270204 Turkey
10270205 Lower Big Blue
10270206 Upper Little Blue
10270207 Lower Little Blue
1028 Chariton-Grand
102801 Grand
10280101 Upper Grand
10280102 Thompson
10280103 Lower Grand
102802 Chariton
10280201 Upper Chariton
10280202 Lower Chariton
10280203 Little Chariton
1029 Gasconade-Osage
102901 Osage
10290101 Upper Marais Des Cygnes
10290102 Lower Marais Des Cygnes
10290103 Little Osage
10290104 Marmaton
10290105 Harry S. Missouri
10290106 Sac
10290107 Pomme De Terre
10290108 South Grand
10290109 Lake of the Ozarks
10290110 Niangua
10290111 Lower Osage
102902 Gasconade
10290201 Upper Gasconade
10290202 Big Piney
10290203 Lower Gasconade
1030 Lower Missouri
103001 Lower Missouri-Blackwater
10300101 Lower Missouri-Crooked
10300102 Lower Missouri-Moreau
10300103 Lamine
10300104 Blackwater
103002 Lower Missouri
10300200 Lower Missouri
11 Arkansas-White-Red
1101 Upper White
110100 Upper White
11010001 Beaver Reservoir
11010002 James
11010003 Bull Shoals Lake
11010004 Middle White
11010005 Buffalo
11010006 North Fork White
11010007 Upper Black
11010008 Current
11010009 Lower Black
11010010 Spring
11010011 Eleven Point
11010012 Strawberry
11010013 Upper White-Village
11010014 Little Red
1102 Upper Arkansas
110200 Upper Arkansas
11020001 Arkansas Headwaters
11020002 Upper Arkansas
11020003 Fountain
11020004 Chico
11020005 Upper Arkansas-Lake Meredith
11020006 Huerfano
11020007 Apishapa
11020008 Horse
11020009 Upper Arkansas-John Martin
11020010 Purgatoire
11020011 Big Sandy
11020012 Rush
11020013 Two Butte
1103 Middle Arkansas
110300 Middle Arkansas
11030001 Middle Arkansas-Lake Mckinney
11030002 Whitewoman
11030003 Arkansas-Dodge City
11030004 Coon-Pickerel
11030005 Pawnee
11030006 Buckner
11030007 Upper Walnut Creek
11030008 Lower Walnut Creek
11030009 Rattlesnake
11030010 Gar-Peace
11030011 Cow
11030012 Little Arkansas
11030013 Middle Arkansas-Slate
11030014 North Fork Ninnescah
11030015 South Fork Ninnescah
11030016 Ninnescah
11030017 Upper Walnut River
11030018 Lower Walnut River
1104 Upper Cimarron
110400 Upper Cimarron
11040001 Cimarron headwaters
11040002 Upper Cimarron
11040003 North Fork Cimarron
11040004 Sand Arroyo
11040005 Bear
11040006 Upper Cimarron-Liberal
11040007 Crooked
11040008 Upper Cimarron-Bluff
1105 Lower Cimarron
110500 Lower Cimarron
11050001 Lower Cimarron-Eagle Chief
11050002 Lower Cimarron-Skeleton
11050003 Lower Cimarron
1106 Arkansas - Keystone
110600 Arkansas - Keystone
11060001 Kaw Lake
11060002 Upper Salt Fork Arkansas
11060003 Medicine Lodge
11060004 Lower Salt Fork Arkansas
11060005 Chikaskia
11060006 Black Bear-Red Rock
1107 Neosho - Verdigris
110701 Verdigris
11070101 Upper Verdigris
11070102 Fall
11070103 Middle Verdigris
11070104 Elk
11070105 Lower Verdigris
11070106 Caney
11070107 Bird
110702 Neosho
11070201 Neosho headwaters
11070202 Upper Cottonwood
11070203 Lower Cottonwood
11070204 Upper Neosho
11070205 Middle Neosho
11070206 Lake O' the Cherokees
11070207 Spring
11070208 Elk
11070209 Lower Neosho
1108 Upper Canadian
110800 Upper Canadian
11080001 Canadian headwaters
11080002 Cimarron
11080003 Upper Canadian
11080004 Mora
11080005 Conchas
11080006 Upper Canadian-Ute Reservoir
11080007 Ute
11080008 Revuelto
1109 Lower Canadian
110901 Middle Canadian
11090101 Middle Canadian-Trujillo
11090102 Punta De Agua
11090103 Rita Blanca
11090104 Carrizo
11090105 Lake Meredith
11090106 Middle Canadian-Spring
110902 Lower Canadian
11090201 Lower Canadian-Deer
11090202 Lower Canadian-Walnut
11090203 Little
11090204 Lower Canadian
1110 North Canadian
111001 Upper Beaver
11100101 Upper Beaver
11100102 Middle Beaver
11100103 Coldwater
11100104 Palo Duro
111002 Lower Beaver
11100201 Lower Beaver
11100202 Upper Wolf
11100203 Lower Wolf
111003 Lower North Canadian
11100301 Middle North Canadian
11100302 Lower North Canadian
11100303 Deep Fork
1111 Lower Arkansas
111101 Robert S. Kerr Reservoir
11110101 Polecat-Snake
11110102 Dirty-Greenleaf
11110103 Illinois
11110104 Robert S. Kerr Reservoir
11110105 Poteau
111102 Lower Arkansas-Fourche La Fave
11110201 Frog-Mulberry
11110202 Dardanelle Reservoir
11110203 Lake Conway-Point Remove
11110204 Petit Jean
11110205 Cadron
11110206 Fourche La Fave
11110207 Lower Arkansas-Maumelle
1112 Red headwaters
111201 Prairie Dog Town Fork Red
11120101 Tierra Blanca
11120102 Palo Duro
11120103 Upper Prairie Dog Town Fork Red
11120104 Tule
11120105 Lower Prairie Dog Town Fork Red
111202 Salt Fork Red
11120201 Upper Salt Fork Red
11120202 Lower Salt Fork Red
111203 North Fork Red
11120301 Upper North Fork Red
11120302 Middle North Fork Red
11120303 Lower North Fork Red
11120304 Elm Fork Red
1113 Red - Washita
111301 Red-Pease
11130101 Groesbeck-Sandy
11130102 Blue-China
11130103 North Pease
11130104 Middle Pease
11130105 Pease
111302 Red-Lake Texoma
11130201 Farmers-Mud
11130202 Cache
11130203 West Cache
11130204 North Wichita
11130205 South Wichita
11130206 Wichita
11130207 Southern Beaver
11130208 Northern Beaver
11130209 Little Wichita
11130210 Lake Texoma
111303 Washita
11130301 Washita headwaters
11130302 Upper Washita
11130303 Middle Washita
11130304 Lower Washita
1114 Red-Sulphur
111401 Red-Little
11140101 Bois D'arc-Island
11140102 Blue
11140103 Muddy Boggy
11140104 Clear Boggy
11140105 Kiamichi
11140106 Pecan-Waterhole
11140107 Upper Little
11140108 Mountain Fork
11140109 Lower Little
111402 Red-Saline
11140201 Mckinney-Posten Bayous
11140202 Middle Red-Coushatta
11140203 Loggy Bayou
11140204 Red Chute
11140205 Bodcau Bayou
11140206 Bayou Pierre
11140207 Lower Red-Lake Iatt
11140208 Saline Bayou
11140209 Black Lake Bayou
111403 Big Cypress - Sulphur
11140301 Sulphur headwaters
11140302 Lower Sulphur
11140303 White Oak Bayou
11140304 Cross Bayou
11140305 Lake O'the Pines
11140306 Caddo Lake
11140307 Little Cypress
12 Texas-Gulf
1201 Sabine
120100 Sabine
12010001 Upper Sabine
12010002 Middle Sabine
12010003 Lake Fork
12010004 Toledo Bend Reservoir
12010005 Lower Sabine
1202 Neches
120200 Neches
12020001 Upper Neches
12020002 Middle Neches
12020003 Lower Neches
12020004 Upper Angelina
12020005 Lower Angelina
12020006 Village
12020007 Pine Island Bayou
1203 Trinity
120301 Upper Trinity
12030101 Upper West Fork Trinity
12030102 Lower West Fork Trinity
12030103 Elm Fork Trinity
12030104 Denton
12030105 Upper Trinity
12030106 East Fork Trinity
12030107 Cedar
12030108 Richland
12030109 Chambers
120302 Lower Trinity
12030201 Lower Trinity-Tehuacana
12030202 Lower Trinity-Kickapoo
12030203 Lower Trinity
1204 Galveston Bay-San Jacinto
120401 San Jacinto
12040101 West Fork San Jacinto
12040102 Spring
12040103 East Fork San Jacinto
12040104 Buffalo-San Jacinto
120402 Galveston Bay-Sabine Lake
12040201 Sabine Lake
12040202 East Galveston Bay
12040203 North Galveston Bay
12040204 West Galveston Bay
12040205 Austin-Oyster
1205 Brazos headwaters
120500 Brazos headwaters
12050001 Yellow House Draw
12050002 Blackwater Draw
12050003 North Fork Double Mountain Fork
12050004 Double Moutain Fork Brazos
12050005 Running Water Draw
12050006 White
12050007 Salt Fork Brazos
1206 Middle Brazos
120601 Middle Brazos-Clear Fork
12060101 Middle Brazos-Millers
12060102 Upper Clear Fork Brazos
12060103 Paint
12060104 Lower Clear Fork Brazos
12060105 Hubbard
120602 Middle Brazos-Bosque
12060201 Middle Brazos-Palo Pinto
12060202 Middle Brazos-Lake Whitney
12060203 Bosque
12060204 North Bosque
1207 Lower Brazos
120701 Lower Brazos
12070101 Lower Brazos-Little Brazos
12070102 Yegua
12070103 Navasota
12070104 Lower Brazos
120702 Little
12070201 Leon
12070202 Cowhouse
12070203 Lampasas
12070204 Little
12070205 San Gabriel
1208 Upper Colorado
120800 Upper Colorado
12080001 Lost Draw
12080002 Colorado headwaters
12080003 Monument-Seminole Draws
12080004 Mustang Draw
12080005 Johnson Draw
12080006 Sulphur Springs Draw
12080007 Beals
12080008 Upper Colorado
1209 Lower Colorado-San Bernard Coastal
120901 Middle Colorado-Concho
12090101 Middle Colorado-Elm
12090102 South Concho
12090103 Middle Concho
12090104 North Concho
12090105 Concho
12090106 Middle Colorado
12090107 Pecan Bayou
12090108 Jim Ned
12090109 San Saba
12090110 Brady
120902 Middle Colorado-Llano
12090201 Buchanan-Lyndon B
12090202 North Llano
12090203 South Llano
12090204 Llano
12090205 Austin-Travis Lakes
12090206 Pedernales
120903 Lower Colorado
12090301 Lower Colorado-Cummins
12090302 Lower Colorado
120904 San Bernard Coastal
12090401 San Bernard
12090402 East Matagorda Bay
1210 Central Texas Coastal
121001 Lavaca
12100101 Lavaca
12100102 Navidad
121002 Guadalupe
12100201 Upper Guadalupe
12100202 Middle Guadalupe
12100203 San Marcos
12100204 Lower Guadalupe
121003 San Antonio
12100301 Upper San Antonio
12100302 Medina
12100303 Lower San Antonio
12100304 Cibolo
121004 Central Texas Coastal
12100401 Central Matagorda Bay
12100402 West Matagorda Bay
12100403 East San Antonio Bay
12100404 West San Antonio Bay
12100405 Aransas Bay
12100406 Mission
12100407 Aransas
1211 Nueces-Southwestern Texas Coastal
121101 Nueces
12110101 Nueces headwaters
12110102 West Nueces
12110103 Upper Nueces
12110104 Turkey
12110105 Middle Nueces
12110106 Upper Frio
12110107 Hondo
12110108 Lower Frio
12110109 San Miguel
12110110 Atascosa
12110111 Lower Nueces
121102 Southwestern Texas Coastal
12110201 North Corpus Christi Bay
12110202 South Corpus Christi Bay
12110203 North Laguna Madre
12110204 San Fernando
12110205 Baffin Bay
12110206 Palo Blanco
12110207 Central Laguna Madre
12110208 South Laguna Madre
13 Rio Grande
1301 Rio Grande headwaters
130100 Rio Grande headwaters
13010001 Rio Grande headwaters
13010002 Alamosa-Trinchera
13010003 San Luis
13010004 Saguache
13010005 Conejos
1302 Rio Grande-Elephant Butte
130201 Upper Rio Grande
13020101 Upper Rio Grande
13020102 Rio Chama
130202 Rio Grande-Elephant Butte
13020201 Rio Grande-Santa Fe
13020202 Jemez
13020203 Rio Grande-Albuquerque
13020204 Rio Puerco
13020205 Arroyo Chico
13020206 North Plains
13020207 Rio San Jose
13020208 Plains of San Agustin
13020209 Rio Salado
13020210 Jornada Del Muerto
13020211 Elephant Butte Reservoir
1303 Rio Grande-Mimbres
130301 Rio Grande-Caballo
13030101 Caballo
13030102 El Paso-Las Cruces
13030103 Jornada Draw
130302 Mimbres
13030201 Playas Lake
13030202 Mimbres
1304 Rio Grande-Amistad
130401 Rio Grande-Fort Quitman
13040100 Rio Grande-Fort Quitman
130402 Rio Grande-Amistad
13040201 Cibolo-Red Light
13040202 Alamito
13040203 Black Hills-Fresno
13040204 Terlingua
13040205 Big Bend
13040206 Maravillas
13040207 Santiago Draw
13040208 Reagan-Sanderson
13040209 San Francisco
13040210 Lozier Canyon
13040211 Big Canyon
13040212 Amistad Reservoir
130403 Devils
13040301 Upper Devils
13040302 Lower Devils
13040303 Dry Devils
1305 Rio Grande closed basins
130500 Rio Grande closed basins
13050001 Western Estancia
13050002 Eastern Estancia
13050003 Tularosa Valley
13050004 Salt Basin
1306 Upper Pecos
130600 Upper Pecos
13060001 Pecos headwaters
13060002 Pintada Arroyo
13060003 Upper Pecos
13060004 Taiban
13060005 Arroyo Del Macho
13060006 Gallo Arroyo
13060007 Upper Pecos-Long Arroyo
13060008 Rio Hondo
13060009 Rio Felix
13060010 Rio Penasco
13060011 Upper Pecos-Black
1307 Lower Pecos
130700 Lower Pecos
13070001 Lower Pecos-Red Bluff Reservoir
13070002 Delaware
13070003 Toyah
13070004 Salt Draw
13070005 Barrilla Draw
13070006 Coyanosa-Hackberry Draws
13070007 Landreth-Monument Draws
13070008 Lower Pecos
13070009 Tunas
13070010 Independence
13070011 Howard Draw
1308 Rio Grande-Falcon
130800 Rio Grande-Falcon
13080001 Elm-Sycamore
13080002 San Ambrosia-Santa Isabel
13080003 International Falcon Reservoir
1309 Lower Rio Grande
130900 Lower Rio Grande
13090001 Los Olmos
13090002 Lower Rio Grande
14 Upper Colorado
1401 Colorado headwaters
140100 Colorado headwaters
14010001 Colorado headwaters
14010002 Blue
14010003 Eagle
14010004 Roaring Fork
14010005 Colorado headwaters-Plateau
14010006 Parachute-Roan
1402 Gunnison
140200 Gunnison
14020001 East-Taylor
14020002 Upper Gunnison
14020003 Tomichi
14020004 North Fork Gunnison
14020005 Lower Gunnison
14020006 Uncompahange
1403 Upper Colorado-Dolores
140300 Upper Colorado-Dolores
14030001 Westwater Canyon
14030002 Upper Dolores
14030003 San Miguel
14030004 Lower Dolores
14030005 Upper Colorado-Kane Springs
1404 Great Divide - Upper Green
140401 Upper Green
14040101 Upper Green
14040102 New Fork
14040103 Upper Green-Slate
14040104 Big Sandy
14040105 Bitter
14040106 Upper Green-Flaming Gorge Reservoir
14040107 Blacks Fork
14040108 Muddy
14040109 Vermilion
140402 Great Divide closed basin
14040200 Great Divide closed basin
1405 White-Yampa
140500 White - Yampa
14050001 Upper Yampa
14050002 Lower Yampa
14050003 Little Snake
14050004 Muddy
14050005 Upper White
14050006 Piceance-Yellow
14050007 Lower White
1406 Lower Green
140600 Lower Green
14060001 Lower Green-Diamond
14060002 Ashley-Brush
14060003 Duchesne
14060004 Strawberry
14060005 Lower Green-Desolation Canyon
14060006 Willow
14060007 Price
14060008 Lower Green
14060009 San Rafael
1407 Upper Colorado-Dirty Devil
140700 Upper Colorado-Dirty Devil
14070001 Upper Lake Powell
14070002 Muddy
14070003 Fremont
14070004 Dirty Devil
14070005 Escalante
14070006 Lower Lake Powell
14070007 Paria
1408 San Juan
140801 Upper San Juan
14080101 Upper San Juan
14080102 Piedra
14080103 Blanco Canyon
14080104 Animas
14080105 Middle San Juan
14080106 Chaco
14080107 Mancos
140802 Lower San Juan
14080201 Lower San Juan-Four Corners
14080202 Mcelmo
14080203 Montezuma
14080204 Chinle
14080205 Lower San Juan
15 Lower Colorado
1501 Lower Colorado-Lake Mead
150100 Lower Colorado-Lake Mead
15010001 Lower Colorado-Marble Canyon
15010002 Grand Canyon
15010003 Kanab
15010004 Havasu Canyon
15010005 Lake Mead
15010006 Grand Wash
15010007 Hualapai Wash
15010008 Upper Virgin
15010009 Fort Pierce Wash
15010010 Lower Virgin
15010011 White
15010012 Muddy
15010013 Meadow Valley Wash
15010014 Detrital Wash
15010015 Las Vegas Wash
1502 Little Colorado
150200 Little Colorado
15020001 Little Colorado headwaters
15020002 Upper Little Colorado
15020003 Carrizo Wash
15020004 Zuni
15020005 Silver
15020006 Upper Puerco
15020007 Lower Puerco
15020008 Middle Little Colorado
15020009 Leroux Wash
15020010 Chevelon Canyon
15020011 Cottonwood Wash
15020012 Corn-Oraibi
15020013 Polacca Wash
15020014 Jadito Wash
15020015 Canyon Diablo
15020016 Lower Little Colorado
15020017 Dinnebito Wash
15020018 Moenkopi Wash
1503 Lower Colorado
150301 Lower Colorado
15030101 Havasu-Mohave Lakes
15030102 Piute Wash
15030103 Sacramento Wash
15030104 Imperial Reservoir
15030105 Bouse Wash
15030106 Tyson Wash
15030107 Lower Colorado
15030108 Yuma Desert
150302 Bill Williams
15030201 Big Sandy
15030202 Burro
15030203 Santa Maria
15030204 Bill Williams
1504 Upper Gila
150400 Upper Gila
15040001 Upper Gila
15040002 Upper Gila-Mangas
15040003 Animas Valley
15040004 San Francisco
15040005 Upper Gila-San Carlos Reservoir
15040006 San Simon
15040007 San Carlos
1505 Middle Gila
150501 Middle Gila
15050100 Middle Gila
150502 San Pedro-Willcox
15050201 Willcox Playa
15050202 Upper San Pedro
15050203 Lower San Pedro
150503 Santa Cruz
15050301 Upper Santa Cruz
15050302 Rillito
15050303 Lower Santa Cruz
15050304 Brawley Wash
15050305 Aguirre Valley
15050306 Santa Rosa Wash
1506 Salt
150601 Salt
15060101 Black
15060102 White
15060103 Upper Salt
15060104 Carrizo
15060105 Tonto
15060106 Lower Salt
150602 Verde
15060201 Big Chino-Williamson Valley
15060202 Upper Verde
15060203 Lower Verde
1507 Lower Gila
150701 Lower Gila-Agua Fria
15070101 Lower Gila-Painted Rock Reservoir
15070102 Agua Fria
15070103 Hassayampa
15070104 Centennial Wash
150702 Lower Gila
15070201 Lower Gila
15070202 Tenmile Wash
15070203 San Cristobal Wash
1508 Sonora
150801 Rio Sonoyta
15080101 San Simon Wash
15080102 Rio Sonoyta
15080103 Tule Desert
150802 Rio De La Concepcion
15080200 Rio De La Concepcion
150803 Rio De Bavispe
15080301 Whitewater Draw
15080302 San Bernardino Valley
15080303 Cloverdale
16 Great Basin
1601 Bear
160101 Upper Bear
16010101 Upper Bear
16010102 Central Bear
160102 Lower Bear
16010201 Bear Lake
16010202 Middle Bear
16010203 Little Bear-Logan
16010204 Lower Bear-Malad
1602 Great Salt Lake
160201 Weber
16020101 Upper Weber
16020102 Lower Weber
160202 Jordan
16020201 Utah Lake
16020202 Spanish Fork
16020203 Provo
16020204 Jordan
160203 Great Salt Lake
16020301 Hamlin-Snake Valleys
16020302 Pine Valley
16020303 Tule Valley
16020304 Rush-Tooele Valleys
16020305 Skull Valley
16020306 Southern Great Salt Lake Desert
16020307 Pilot-Thousand Springs
16020308 Northern Great Salt Lake Desert
16020309 Curlew Valley
16020310 Great Salt Lake
1603 Escalante Desert-Sevier Lake
160300 Escalante Desert-Sevier Lake
16030001 Upper Sevier
16030002 East Fork Sevier
16030003 Middle Sevier
16030004 San Pitch
16030005 Lower Sevier
16030006 Escalante Desert
16030007 Beaver Bottoms-Upper Beaver
16030008 Lower Beaver
16030009 Sevier Lake
1604 Black Rock Desert-Humboldt
160401 Humboldt
16040101 Upper Humboldt
16040102 North Fork Humboldt
16040103 South Fork Humboldt
16040104 Pine
16040105 Middle Humboldt
16040106 Rock
16040107 Reese
16040108 Lower Humboldt
16040109 Little Humboldt
160402 Black Rock Desert
16040201 Upper Quinn
16040202 Lower Quinn
16040203 Smoke Creek Desert
16040204 Massacre Lake
16040205 Thousand-Virgin
1605 Central Lahontan
160501 Truckee
16050101 Lake Tahoe
16050102 Truckee
16050103 Pyramid-Winnemucca Lakes
16050104 Granite Springs Valley
160502 Carson
16050201 Upper Carson
16050202 Middle Carson
16050203 Carson Desert
160503 Walker
16050301 East Walker
16050302 West Walker
16050303 Walker
16050304 Walker Lake
1606 Central Nevada Desert Basins
160600 Central Nevada Desert Basins
16060001 Dixie Valley
16060002 Gabbs Valley
16060003 Southern Big Smoky Valley
16060004 Northern Big Smoky Valley
16060005 Diamond-Monitor Valleys
16060006 Little Smoky-Newark Valleys
16060007 Long-Ruby Valleys
16060008 Spring-Steptoe Valleys
16060009 Dry Lake Valley
16060010 Fish Lake-Soda Spring Valleys
16060011 Ralston-Stone Cabin Valleys
16060012 Hot Creek-Railroad Valleys
16060013 Cactus-Sarcobatus Flats
16060014 Sand Spring-Tikaboo Valleys
16060015 Ivanpah-Pahrump Valleys
17 Pacific Northwest
1701 Kootenai-Pend Oreille-Spokane
170101 Kootenai
17010101 Upper Kootenai
17010102 Fisher
17010103 Yaak
17010104 Lower Kootenai
17010105 Moyie
170102 Pend Oreille
17010201 Upper Clark Fork
17010202 Flint-Rock
17010203 Blackfoot
17010204 Middle Clark Fork
17010205 Bitterroot
17010206 North Fork Flathead
17010207 Middle Fork Flathead
17010208 Flathead Lake
17010209 South Fork Flathead
17010210 Stillwater
17010211 Swan
17010212 Lower Flathead
17010213 Lower Clark Fork
17010214 Pend Oreille Lake
17010215 Priest
17010216 Pend Oreille
170103 Spokane
17010301 Upper Coeur D'alene
17010302 South Fork Coeur D'alene
17010303 Coeur D'alene Lake
17010304 St. Joe
17010305 Upper Spokane
17010306 Hangman
17010307 Lower Spokane
17010308 Little Spokane
1702 Upper Columbia
170200 Upper Columbia
17020001 Franklin D. Roosevelt Lake
17020002 Kettle
17020003 Colville
17020004 Sanpoil
17020005 Chief Joseph
17020006 Okanogan
17020007 Similkameen
17020008 Methow
17020009 Lake Chelan
17020010 Upper Columbia-Entiat
17020011 Wenatchee
17020012 Moses Coulee
17020013 Upper Crab
17020014 Banks Lake
17020015 Lower Crab
17020016 Upper Columbia-Priest Rapids
1703 Yakima
170300 Yakima
17030001 Upper Yakima
17030002 Naches
17030003 Lower Yakima, Washington
1704 Upper Snake
170401 Snake headwaters
17040101 Snake headwaters
17040102 Gros Ventre
17040103 Greys-Hobock
17040104 Palisades
17040105 Salt
170402 Upper Snake
17040201 Idaho Falls
17040202 Upper Henrys
17040203 Lower Henrys
17040204 Teton
17040205 Willow
17040206 American Falls
17040207 Blackfoot
17040208 Portneuf
17040209 Lake Walcott
17040210 Raft
17040211 Goose
17040212 Upper Snake-Rock
17040213 Salmon Falls
17040214 Beaver-Camas
17040215 Medicine Lodge
17040216 Birch
17040217 Little Lost
17040218 Big Lost
17040219 Big Wood
17040220 Camas
17040221 Little Wood
1705 Middle Snake
170501 Middle Snake-Boise
17050101 C. J. Idaho
17050102 Bruneau
17050103 Middle Snake-Succor
17050104 Upper Owyhee
17050105 South Fork Owyhee
17050106 East Little Owyhee. Nevada,
17050107 Middle Owyhee
17050108 Jordan
17050109 Crooked-Rattlesnake
17050110 Lower Owyhee
17050111 North and Middle Forks Boise
17050112 Boise-Mores
17050113 South Fork Boise
17050114 Lower Boise
17050115 Middle Snake-Payette
17050116 Upper Malheur
17050117 Lower Malheur
17050118 Bully
17050119 Willow
17050120 South Fork Payette
17050121 Middle Fork Payette
17050122 Payette
17050123 North Fork Payette
17050124 Weiser
170502 Middle Snake-Powder
17050201 Brownlee Reservoir
17050202 Burnt
17050203 Powder
1706 Lower Snake
170601 Lower Snake
17060101 Hells Canyon
17060102 Imnaha
17060103 Lower Snake-Asotin
17060104 Upper Grande Ronde
17060105 Wallowa
17060106 Lower Grande Ronde
17060107 Lower Snake-Tucannon
17060108 Palouse
17060109 Rock
17060110 Lower Snake
170602 Salmon
17060201 Upper Salmon
17060202 Pahsimeroi
17060203 Middle Salmon-Panther
17060204 Lemhi
17060205 Upper Middle Fork Salmon
17060206 Lower Middle Fork Salmon
17060207 Middle Salmon-Chamberlain
17060208 South Fork Salmon
17060209 Lower Salmon
17060210 Little Salmon
170603 Clearwater
17060301 Upper Selway
17060302 Lower Selway
17060303 Lochsa
17060304 Middle Fork Clearwater
17060305 South Fork Clearwater
17060306 Clearwater
17060307 Upper North Fork Clearwater
17060308 Lower North Fork Clearwater
1707 Middle Columbia
170701 Middle Columbia
17070101 Middle Columbia-Lake Wallula
17070102 Walla Walla
17070103 Umatilla
17070104 Willow
17070105 Middle Columbia-Hood
17070106 Klickitat
170702 John Day
17070201 Upper John Day
17070202 North Fork John Day
17070203 Middle Fork John Day
17070204 Lower John Day
170703 Deschutes
17070301 Upper Deschutes
17070302 Little Deschutes
17070303 Beaver-South Fork
17070304 Upper Crooked
17070305 Lower Crooked
17070306 Lower Deschutes
17070307 Trout
1708 Lower Columbia
170800 Lower Columbia
17080001 Lower Columbia-Sandy
17080002 Lewis
17080003 Lower Columbia-Clatskanie
17080004 Upper Cowlitz
17080005 Lower Cowlitz
17080006 Lower Columbia
1709 Willamette
170900 Willamette
17090001 Middle Fork Willamette
17090002 Coast Fork Willamette
17090003 Upper Willamette
17090004 Mckenzie
17090005 North Santiam
17090006 South Santiam
17090007 Middle Willamette
17090008 Yamhill
17090009 Molalla-Pudding
17090010 Tualatin
17090011 Clackamas
17090012 Lower Willamette
1710 Oregon-Washington Coastal
171001 Washington Coastal
17100101 Hoh-Quillayute
17100102 Queets-Quinault
17100103 Upper Chehalis
17100104 Lower Chehalis
17100105 Grays Harbor
17100106 Willapa Bay
171002 Northern Oregon Coastal
17100201 Necanicum
17100202 Nehalem
17100203 Wilson-Trask-Nestucca
17100204 Siletz-Yaquina
17100205 Alsea
17100206 Siuslaw
17100207 Siltcoos
171003 Southern Oregon Coastal
17100301 North Umpqua
17100302 South Umpqua
17100303 Umpqua
17100304 Coos
17100305 Coquille
17100306 Sixes
17100307 Upper Rogue
17100308 Middle Rogue
17100309 Applegate
17100310 Lower Rogue
17100311 Illinois
17100312 Chetco
1711 Puget Sound
171100 Puget Sound
17110001 Fraser
17110002 Strait of Georgia
17110003 San Juan Islands
17110004 Nooksack
17110005 Upper Skagit
17110006 Sauk
17110007 Lower Skagit
17110008 Stillaguamish
17110009 Skykomish
17110010 Snoqualmie
17110011 Snohomish
17110012 Lake Washington
17110013 Duwamish
17110014 Puyallup
17110015 Nisqually
17110016 Deschutes
17110017 Skokomish
17110018 Hood Canal
17110019 Puget Sound
17110020 Dungeness-Elwha
17110021 Crescent-Hoko
1712 Oregon closed basins
171200 Oregon closed basins
17120001 Harney-Malheur Lakes
17120002 Silvies
17120003 Donner Und Blitzen
17120004 Silver
17120005 Summer Lake
17120006 Lake Abert
17120007 Warner Lakes
17120008 Guano
17120009 Alvord Lake
18 California
1801 Klamath-Northern California Coastal
180101 Northern California Coastal
18010101 Smith
18010102 Mad-Redwood
18010103 Upper Eel
18010104 Middle Fork Eel
18010105 Lower Eel
18010106 South Fork Eel
18010107 Mattole
18010108 Big-Navarro-Garcia
18010109 Gualala-Salmon
18010110 Russian
18010111 Bodega Bay
180102 Klamath
18010201 Williamson
18010202 Sprague
18010203 Upper Klamath Lake
18010204 Lost
18010205 Butte
18010206 Upper Klamath
18010207 Shasta
18010208 Scott
18010209 Lower Klamath
18010210 Salmon
18010211 Trinity
18010212 South Fork Trinity
1802 Sacramento
180200 Upper Sacramento
18020001 Goose Lake
18020002 Upper Pit
18020003 Lower Pit
18020004 Mccloud
18020005 Sacramento headwaters
180201 Lower Sacramento
18020101 Sacramento-Lower Cow-Lower Clear
18020102 Lower Cottonwood
18020103 Sacramento-Lower Thomes
18020104 Sacramento-Stone Corral
18020105 Lower Butte
18020106 Lower Feather
18020107 Lower Yuba
18020108 Lower Bear
18020109 Lower Sacramento
18020110 Lower Cache
18020111 Lower American
18020112 Sacramento-Upper Clear
18020113 Cottonwood headwaters
18020114 Upper Elder-Upper Thomes
18020115 Upper Stony
18020116 Upper Cache
18020117 Upper Putah
18020118 Upper Cow-Battle
18020119 Mill-Big Chico
18020120 Upper Butte
18020121 North Fork Feather
18020122 East Branch North Fork Feather
18020123 Middle Fork Feather
18020124 Honcut headwaters
18020125 Upper Yuba
18020126 Upper Bear
18020127 Upper Coon-Upper Auburn
18020128 North Fork American
18020129 South Fork American
1803 Tulare-Buena Vista Lakes
180300 Tulare-Buena Vista Lakes
18030001 Upper Kern
18030002 South Fork Kern
18030003 Middle Kern-Upper Tehachapi-
18030004 Upper Poso
18030005 Upper Deer-Upper White
18030006 Upper Tule
18030007 Upper Kaweah
18030008 Mill
18030009 Upper Dry
18030010 Upper King
18030011 Upper Los Gatos-Avenal
18030012 Tulare-Buena Vista Lakes
1804 San Joaquin
180400 San Joaquin
18040001 Middle San Joaquin-Lower
18040002 Middle San Joaquin-Lower
18040003 San Joaquin Delta
18040004 Lower Calaveras-Mormon Slough
18040005 Lower Cosumnes-Lower Mokelumne
18040006 Upper San Joaquin
18040007 Upper Chowchilla-Upper Fresno
18040008 Upper Merced
18040009 Upper Tuolumne
18040010 Upper Stanislaus
18040011 Upper Calaveras
18040012 Upper Mokelumne
18040013 Upper Cosumnes
18040014 Panoche-San Luis Reservoir
1805 San Francisco Bay
180500 San Francisco Bay
18050001 Suisun Bay
18050002 San Pablo Bay
18050003 Coyote
18050004 San Francisco Bay
18050005 Tomales-Drake Bays
18050006 San Francisco Coastal South
1806 Central California Coastal
180600 Central California Coastal
18060001 San Lorenzo-Soquel
18060002 Pajaro
18060003 Carrizo Plain
18060004 Estrella
18060005 Salinas
18060006 Central Coastal
18060007 Cuyama
18060008 Santa Maria
18060009 San Antonio
18060010 Santa Ynez
18060011 Alisal-Elkhorn Sloughs
18060012 Carmel
18060013 Santa Barbara Coastal
18060014 Santa Barbara Channel Islands
1807 Southern California Coastal
180701 Ventura-San Gabriel Coastal
18070101 Ventura
18070102 Santa Clara
18070103 Calleguas
18070104 Santa Monica Bay
18070105 Los Angeles
18070106 San Gabriel
18070107 San Pedro Channel Islands
180702 Santa Ana
18070201 Seal Beach
18070202 San Jacinto
18070203 Santa Ana
18070204 Newport Bay
180703 Laguna-San Diego Coastal
18070301 Aliso-San Onofre
18070302 Santa Margarita
18070303 San Luis Rey-Escondido
18070304 San Diego
18070305 Cottonwood-Tijuana
1808 North Lahontan
180800 North Lahontan
18080001 Surprise Valley
18080002 Madeline Plains
18080003 Honey-Eagle Lakes
1809 Northern Mojave-Mono Lake
180901 Mono-Owens Lakes
18090101 Mono Lake
18090102 Crowley Lake
18090103 Owens Lake
180902 Northern Mojave
18090201 Eureka-Saline Valleys
18090202 Upper Amargosa
18090203 Death Valley-Lower Amargosa
18090204 Panamint Valley
18090205 Indian Wells-Searles Valleys
18090206 Antelope-Fremont Valleys
18090207 Coyote-Cuddeback Lakes
18090208 Mojave
1810 Southern Mojave-Salton Sea
181001 Southern Mojave
18100100 Southern Mojave
181002 Salton Sea
18100200 Salton Sea
19 Alaska
1901 Southeast
190101 Southern Southeast
19010101 Southeast Mainland
19010102 Ketchikan
19010103 Prince of Wales
190102 Central Southeast
19010201 Mainland
19010202 Kuiu-Kupreanof-Mitkof-Etolin-Zarembo-Wrangell Islands
19010203 Baranof-Chichagof Islands
19010204 Admiralty Island
190103 Northern Southeast
19010301 Lynn Canal
19010302 Glacier Bay
19010303 Chilkat-Skagway Rivers
190104 Gulf of Alaska
19010401 Yakutat Bay
19010402 Bering Glacier
1902 Southcentral
190201 Copper River
19020101 Upper Copper River
19020102 Middle Copper River
19020103 Chitina River
19020104 Lower Copper River
190202 Prince William Sound
19020201 Eastern Prince William Sound
19020202 Western Prince William Sound
190203 Kenai Peninsula
19020301 Lower Kenai Peninsula
19020302 Upper Kenai Peninsula
190204 Knik Arm
19020401 Anchorage
19020402 Matansuka
190205 Susitna River
19020501 Upper Susitna River
19020502 Chulitna River
19020503 Talkeetna River
19020504 Yentna River
19020505 Lower Susitna River
190206 Western Cook Inlet
19020601 Redoubt-Trading Bays
19020602 Tuxdeni-Kamishak Bays
190207 Kodiak-Shelikof
19020701 Kodiak-Afognak Islands
19020702 Shelikof Straight
1903 Southwest
190301 Aleutian Islands
19030101 Cold Bay
19030102 Fox Islands
19030103 Western Aleutian
19030104 Pribilof Islands
190302 Kvichak-Port Heiden
19030201 Port Heiden
19030202 Ugashik Bay
19030203 Egegik Bay
19030204 Naknek
19030205 Lake Clark
19030206 Lake Iliamna
190303 Nushagak River
19030301 Upper Nushagak River
19030302 Mulchatna River
19030303 Lower Nushagak River
19030304 Wood River
19030305 Togiak
190304 Upper Kuskokwim River
19030401 North Fork Kuskokwim River
19030402 Farewll Lake
19030403 Takotna River
19030404 Holitna River
19030405 Stony River
190305 Lower Kuskokwim River
19030501 Aniak
19030502 Kuskokwim Delta
19030503 Nunavak-St. Matthew Islands
1904 Yukon
190401 Canada
19040101 White River
19040102 Ladue River
19040103 Sixtymile River
19040104 Fortymile River
190402 Porcupine River
19040201 Old Crow River
19040202 Coleen River
19040203 Sheenjek River
19040204 Black River
19040205 Porcupine Flats
190403 Chandalar-Christian Rivers
19040301 Middle Fork-North Fork Chandalar Rivers
19040302 East Fork Chandalar River
19040303 Christian River
19040304 Lower Chandalar River
190404 Upper Yukon River
19040401 Eagle To Circle
19040402 Birch-Beaver Creeks
19040403 Yukon Flats
19040404 Ramparts
190405 Tanana River
19040501 Nebesna-Chisana Rivers
19040502 Tok
19040503 Healy Lake
19040504 Delta River
19040505 Salcha River
19040506 Chena River
19040507 Tanana River
19040508 Nenana River
19040509 Tolovana River
19040510 Kantishna River
19040511 Lower Tanana River
190406 Koyukuk River
19040601 Upper Koyukuk River
19040602 South Fork Koyukuk River
19040603 Alatna River
19040604 Kanuti River
19040605 Allakaket River
19040606 Huslia River
19040607 Dulbi River
19040608 Koyukuk Flats
19040609 Kateel River
190407 Central Yukon
19040701 Tozitna River
19040702 Nowitna River
19040703 Melozitna River
19040704 Ramparts to Ruby
19040705 Galena
190408 Lower Yukon
19040801 Anvik River
19040802 Upper Innoko River
19040803 Lower Innoko River
19040804 Anvik to Pilot Station
19040805 Yukon Delta
1905 Northwest
190501 Norton Sound
19050101 St. Lawrence Island
19050102 Unalakleet
19050103 Norton Bay
19050104 Nome
19050105 Imuruk Basin
190502 Northern Seward Peninsula
19050201 Shishmaref
19050202 Goodhope-Spafarief Bay
19050203 Buckland River
190503 Kobuk-Selawik Rivers
19050301 Selawik Lake
19050302 Upper Kobuk River
19050303 Middle Kobuk River
19050304 Lower Kobuk River
190504 Noatak River-Lisburne Peninsula
19050401 Upper Noatak River
19050402 Middle Noatak River
19050403 Lower Noatak River
19050404 Wulik-Kivalina Rivers
19050405 Lisburne Peninsula
1906 Arctic
190601 Western Arctic
19060101 Kukpowruk River
19060102 Kokolik River
19060103 Utukok River
190602 Barrow
19060201 Kuk River
19060202 Northwest Coast
19060203 Meade River
19060204 Ikpikpuk River
19060205 Harrison Bay
190603 Colville River
19060301 Upper Colville River
19060302 Killik River
19060303 Chandler-Anaktuvuk Rivers
19060304 Lower Colville River
190604 Prudhoe Bay
19060401 Kuparuk River
19060402 Sagavanirktok River
19060403 Mikkelson Bay
190605 Eastern Arctic
19060501 Canning River
19060502 Camden Bay
19060503 Beaufort Lagoon
20 Hawaii
2001 Hawaii
200100 Hawaii
20010000 Hawaii
2002 Maui
200200 Maui
20020000 Maui
2003 Kahoolawe
200300 Kahoolawe
20030000 Kahoolawe
2004 Lanai
200400 Lanai
20040000 Lanai
2005 Molokai
200500 Molokai
20050000 Molokai
2006 Oahu
200600 Oahu
20060000 Oahu
2007 Kauai
200700 Kauai
20070000 Kauai
2008 Niihau
200800 Niihau
20080000 Niihau
2009 Northwestern Hawaiian Islands
200900 Northwestern Hawaiian Islands
20090000 Northwestern Hawaiian Islands
21 Caribbean
2101 Puerto Rico
210100 Puerto Rico
21010001 Interior Puerto Rico
21010002 Cibuco-Guajataca
21010003 Culebrinas-Guanajibo
21010004 Southern Puerto Rico
21010005 Eastern Puerto Rico
21010006 Puerto Rican Islands
2102 Virgin Islands
210200 Virgin Islands
21020001 St. John-St. Thomas
21020002 St. Croix
2103 Caribbean Outlying Areas
210300 Caribbean Outlying Areas
21030001 Canal Zone
21030002 Navassa
21030003 Roncador-Serrana
</pre>
</td>
</tr>
</tbody>
</table>
<div align="center" class="bottombox"><span class="info"></span></div>
<!--#include virtual="/inc/footer_water.html" -->
<!--#include virtual="/inc/footer.html" -->
</body>
</html>"""
|
# Copyright 2020 Joshua Laniado and Todd O. Yeates.
__author__ = "Joshua Laniado and Todd O. Yeates"
__copyright__ = "Copyright 2020, Nanohedra"
__version__ = "1.0"
# SYMMETRY COMBINATION MATERIAL TABLE (T.O.Y and J.L, 2020)
sym_comb_dict = {
1: [1, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'C2', 1, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'D2', 'D2', 0, 'N/A', 4, 2],
2: [2, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'C3', 2, ['r:<0,0,1,c>'], 1, '<e,0.577350*e,0>', 'C6', 'p6', 2, '(2*e, 2*e), 120', 4, 6],
3: [3, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'D3', 'D3', 0, 'N/A', 4, 2],
4: [4, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 6, '<e,0,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'D3', 'p312', 2, '(2*e, 2*e), 120', 5, 6],
5: [5, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 4, '<0,0,0>', 'T', 'T', 0, 'N/A', 4, 3],
6: [6, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,e,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 4, '<0,0,0>', 'T', 'I213', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 5, 10],
7: [7, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<0,0,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 4, '<0,0,0>', 'O', 'O', 0, 'N/A', 4, 4],
8: [8, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<2*e,e,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 4, '<0,0,0>', 'O', 'P4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 5, 10],
9: [9, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 7, '<0,0,0>', 'I', 'I', 0, 'N/A', 4, 5],
10: [10, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'C4', 3, ['r:<0,0,1,c>'], 1, '<0,0,0>', 'C4', 'p4', 2, '(2*e, 2*e), 90', 4, 4],
11: [11, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'C4', 3, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'D4', 'D4', 0, 'N/A', 4, 2],
12: [12, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 8, '<0,0,0>', 'C4', 3, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<e,0,0>', 'D4', 'p4212', 2, '(2*e, 2*e), 90', 5, 4],
13: [13, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<0,0,0>', 'C4', 3, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'O', 'O', 0, 'N/A', 4, 3],
14: [14, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<2*e,e,0>', 'C4', 3, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 5, 8],
15: [15, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'C5', 4, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'D5', 'D5', 0, 'N/A', 4, 2],
16: [16, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'C5', 4, ['r:<0,0,1,c>', 't:<0,0,d>'], 9, '<0,0,0>', 'I', 'I', 0, 'N/A', 4, 3],
17: [17, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'C6', 5, ['r:<0,0,1,c>'], 1, '<0,0,0>', 'C6', 'p6', 2, '(2*e, 2*e), 120', 4, 3],
18: [18, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'C6', 5, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'D6', 'D6', 0, 'N/A', 4, 2],
19: [19, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 6, '<e,0,0>', 'C6', 5, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 5, 4],
20: [20, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,f,0>', 'D2', 6, ['None'], 1, '<0,0,0>', 'D2', 'c222', 2, '(4*e, 4*f), 90', 4, 4],
21: [21, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 8, '<0,0,0>', 'D2', 6, ['None'], 1, '<e,0,0>', 'D4', 'p422', 2, '(2*e, 2*e), 90', 3, 4],
22: [22, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,e,f>', 'D2', 6, ['None'], 5, '<0,0,0>', 'D4', 'I4122', 3, '(4*e, 4*e, 8*f), (90, 90, 90)', 4, 6],
23: [23, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 10, '<0,0,0>', 'D2', 6, ['None'], 1, '<e,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 3, 3],
24: [24, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 10, '<0,0,e>', 'D2', 6, ['None'], 1, '<f,0,0>', 'D6', 'P6222', 3, '(2*f, 2*f, 6*e), (90, 90, 120)', 4, 6],
25: [25, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<0,0,0>', 'D2', 6, ['None'], 5, '<2*e,0,e>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 4],
26: [26, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<-2*e,3*e,0>', 'D2', 6, ['None'], 5, '<0,2*e,e>', 'O', 'I4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 3, 3],
27: [27, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 6, '<e,0,0>', 'D3', 7, ['None'], 11, '<0,0,0>', 'D3', 'p312', 2, '(2*e, 2*e), 120', 3, 3],
28: [28, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,e,f>', 'D3', 7, ['None'], 1, '<0,0,0>', 'D3', 'R32', 3, '(3.4641*e, 3.4641*e, 3*f), (90, 90, 120)', 4, 4],
29: [29, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 3, 2],
30: [30, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 3, 2],
31: [31, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,f>', 'D6', 'P6322', 3, '(2*e, 2*e, 4*f), (90, 90, 120)', 4, 4],
32: [32, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'D3', 7, ['None'], 4, '<e,e,e>', 'O', 'F4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 3, 3],
33: [33, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,2*e,0>', 'D3', 7, ['None'], 4, '<e,e,e>', 'O', 'I4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 3, 2],
34: [34, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<0,0,0>', 'D3', 7, ['None'], 4, '<e,e,e>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 4],
35: [35, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<0,e,-2*e>', 'D3', 7, ['None'], 4, '<e,e,e>', 'O', 'I4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 3, 2],
36: [36, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<0,e,-2*e>', 'D3', 7, ['None'], 4, '<3*e,3*e,3*e>', 'O', 'P4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 3, 3],
37: [37, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 'p422', 2, '(2*e, 2*e), 90', 3, 2],
38: [38, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,e,0>', 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 'p422', 2, '(2*e, 2*e), 90', 3, 2],
39: [39, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 8, '<0,e,f>', 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 'I422', 3, '(2*e, 2*e, 4*f), (90, 90, 90)', 4, 4],
40: [40, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<0,0,0>', 'D4', 8, ['None'], 1, '<0,0,e>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 3],
41: [41, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<2*e,e,0>', 'D4', 8, ['None'], 1, '<2*e,2*e,0>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 2],
42: [42, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'D6', 9, ['None'], 1, '<0,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 3, 2],
43: [43, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 6, '<e,0,0>', 'D6', 9, ['None'], 1, '<0,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 3, 2],
44: [44, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 6, '<e,0,f>', 'D6', 9, ['None'], 1, '<0,0,0>', 'D6', 'P622', 3, '(2*e, 2*e, 2*f), (90, 90, 120)', 4, 4],
45: [45, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'T', 10, ['None'], 1, '<0,0,0>', 'T', 'P23', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
46: [46, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,e,0>', 'T', 10, ['None'], 1, '<0,0,0>', 'T', 'F23', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 3],
47: [47, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<2*e,3*e,0>', 'T', 10, ['None'], 1, '<0,4*e,0>', 'O', 'F4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 3, 2],
48: [48, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
49: [49, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,e,0>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'F432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 2],
50: [50, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<e,0,0>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'F432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
51: [51, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<0,e,0>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
52: [52, 'C2', 1, ['r:<0,0,1,a>', 't:<0,0,b>'], 3, '<-e,e,e>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 2],
53: [53, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'C3', 2, ['r:<0,0,1,c>'], 1, '<e,0.57735*e,0>', 'C3', 'p3', 2, '(2*e, 2*e), 120', 4, 3],
54: [54, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<0,0,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 12, '<0,0,0>', 'T', 'T', 0, 'N/A', 4, 2],
55: [55, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<0,0,0>', 'C3', 2, ['r:<0,0,1,c>', 't:<0,0,d>'], 12, '<e,0,0>', 'T', 'P213', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 5, 5],
56: [56, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<0,0,0>', 'C4', 3, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<0,0,0>', 'O', 'O', 0, 'N/A', 4, 2],
57: [57, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<0,0,0>', 'C4', 3, ['r:<0,0,1,c>', 't:<0,0,d>'], 1, '<e,0,0>', 'O', 'F432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 5, 6],
58: [58, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 7, '<0,0,0>', 'C5', 4, ['r:<0,0,1,c>', 't:<0,0,d>'], 9, '<0,0,0>', 'I', 'I', 0, 'N/A', 4, 2],
59: [59, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0.57735*e,0>', 'C6', 5, ['r:<0,0,1,c>'], 1, '<0,0,0>', 'C6', 'p6', 2, '(2*e, 2*e), 120', 4, 2],
60: [60, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0.57735*e,0>', 'D2', 6, ['None'], 1, '<e,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 3, 2],
61: [61, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<0,0,0>', 'D2', 6, ['None'], 1, '<e,0,0>', 'T', 'P23', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 3],
62: [62, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<0,0,0>', 'D2', 6, ['None'], 3, '<e,0,e>', 'O', 'F432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 3],
63: [63, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<0,0,0>', 'D2', 6, ['None'], 3, '<2*e,e,0>', 'O', 'I4132', 3, '(8*e,8*e, 8*e), (90, 90, 90)', 3, 2],
64: [64, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0.57735*e,0>', 'D3', 7, ['None'], 11, '<0,0,0>', 'D3', 'p312', 2, '(2*e, 2*e), 120', 3, 2],
65: [65, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0.57735*e,0>', 'D3', 7, ['None'], 1, '<0,0,0>', 'D3', 'p321', 2, '(2*e, 2*e), 120', 3, 2],
66: [66, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 12, '<4*e,0,0>', 'D3', 7, ['None'], 4, '<3*e,3*e,3*e>', 'O', 'P4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 3, 4],
67: [67, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<0,0,0>', 'D4', 8, ['None'], 1, '<0,0,e>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
68: [68, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0.57735*e,0>', 'D6', 9, ['None'], 1, '<0,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 3, 2],
69: [69, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<e,0,0>', 'T', 10, ['None'], 1, '<0,0,0>', 'T', 'F23', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
70: [70, 'C3', 2, ['r:<0,0,1,a>', 't:<0,0,b>'], 4, '<e,0,0>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'F432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
71: [71, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'C4', 3, ['r:<0,0,1,c>'], 1, '<e,e,0>', 'C4', 'p4', 2, '(2*e, 2*e), 90', 4, 2],
72: [72, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'C4', 3, ['r:<0,0,1,c>', 't:<0,0,d>'], 2, '<0,e,e>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 5, 4],
73: [73, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'D2', 6, ['None'], 1, '<e,0,0>', 'D4', 'p422', 2, '(2*e, 2*e), 90', 3, 2],
74: [74, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,0,0>', 'D2', 6, ['None'], 5, '<0,0,0>', 'D4', 'p4212', 2, '(2*e, 2*e), 90', 3, 2],
75: [75, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'D2', 6, ['None'], 3, '<2*e,e,0>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 2],
76: [76, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'D2', 6, ['None'], 3, '<e,0,e>', 'O', 'F432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 3],
77: [77, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'D3', 7, ['None'], 4, '<e,e,e>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 2],
78: [78, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,e,0>', 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 'p422', 2, '(2*e, 2*e), 90', 3, 2],
79: [79, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 2, '<0,0,0>', 'D4', 8, ['None'], 1, '<e,e,0>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
80: [80, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'T', 10, ['None'], 1, '<e,e,e>', 'O', 'F432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 3, 2],
81: [81, 'C4', 3, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<e,e,0>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 3, 2],
82: [82, 'C6', 5, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'D2', 6, ['None'], 1, '<e,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 3, 2],
83: [83, 'C6', 5, ['r:<0,0,1,a>', 't:<0,0,b>'], 1, '<0,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 2, 2],
84: [84, 'D2', 6, ['None'], 1, '<0,0,0>', 'D2', 6, ['None'], 1, '<e,f,0>', 'D2', 'p222', 2, '(2*e, 2*f), 90', 2, 2],
85: [85, 'D2', 6, ['None'], 1, '<0,0,0>', 'D2', 6, ['None'], 1, '<e,f,g>', 'D2', 'F222', 3, '(4*e, 4*f, 4*g), (90, 90, 90)', 3, 3],
86: [86, 'D2', 6, ['None'], 1, '<e,0,0>', 'D2', 6, ['None'], 5, '<0,0,f>', 'D4', 'P4222', 3, '(2*e, 2*e, 4*f), (90, 90, 90)', 2, 2],
87: [87, 'D2', 6, ['None'], 1, '<e,0,0>', 'D2', 6, ['None'], 13, '<0,0,-f>', 'D6', 'P6222', 3, '(2*e, 2*e, 6*f), (90, 90, 120)', 2, 2],
88: [88, 'D2', 6, ['None'], 3, '<0,e,2*e>', 'D2', 6, ['None'], 5, '<0,2*e,e>', 'O', 'P4232', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 2],
89: [89, 'D2', 6, ['None'], 1, '<e,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 1, 1],
90: [90, 'D2', 6, ['None'], 1, '<e,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,f>', 'D6', 'P622', 3, '(2*e, 2*e, 2*f), (90, 90, 120)', 2, 2],
91: [91, 'D2', 6, ['None'], 1, '<0,0,2*e>', 'D3', 7, ['None'], 4, '<e,e,e>', 'D6', 'P4232', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 2],
92: [92, 'D2', 6, ['None'], 3, '<2*e,e,0>', 'D3', 7, ['None'], 4, '<e,e,e>', 'O', 'I4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 1, 1],
93: [93, 'D2', 6, ['None'], 1, '<e,0,0>', 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 'p422', 2, '(2*e, 2*e), 90', 1, 1],
94: [94, 'D2', 6, ['None'], 1, '<e,0,f>', 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 'P422', 3, '(2*e, 2*e, 2*f), (90, 90,90)', 2, 2],
95: [95, 'D2', 6, ['None'], 5, '<e,0,f>', 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 'I422', 3, '(2*e, 2*e, 4*f), (90, 90,90)', 2, 2],
96: [96, 'D2', 6, ['None'], 3, '<0,e,2*e>', 'D4', 8, ['None'], 1, '<0,0,2*e>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 1],
97: [97, 'D2', 6, ['None'], 1, '<e,0,0>', 'D6', 9, ['None'], 1, '<0,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 1, 1],
98: [98, 'D2', 6, ['None'], 1, '<e,0,f>', 'D6', 9, ['None'], 1, '<0,0,0>', 'D6', 'P622', 3, '(2*e, 2*e, 2*f), (90, 90, 120)', 2, 2],
99: [99, 'D2', 6, ['None'], 1, '<e,0,0>', 'T', 10, ['None'], 1, '<0,0,0>', 'T', 'P23', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 1, 1],
100: [100, 'D2', 6, ['None'], 1, '<e,e,0>', 'T', 10, ['None'], 1, '<0,0,0>', 'T', 'P23', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 1, 2],
101: [101, 'D2', 6, ['None'], 3, '<e,0,e>', 'T', 10, ['None'], 1, '<e,e,e>', 'O', 'F432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 1],
102: [102, 'D2', 6, ['None'], 3, '<2*e,e,0>', 'T', 10, ['None'], 1, '<0,0,0>', 'O', 'P4232', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 2],
103: [103, 'D2', 6, ['None'], 3, '<e,0,e>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'F432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 1],
104: [104, 'D2', 6, ['None'], 3, '<2*e,e,0>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 2],
105: [105, 'D3', 7, ['None'], 11, '<0,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,0>', 'D3', 'p312', 2, '(2*e, 2*e), 120', 1, 1],
106: [106, 'D3', 7, ['None'], 11, '<0,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,f>', 'D3', 'P312', 3, '(2*e, 2*e, 2*f), (90, 90, 120)', 2, 2],
107: [107, 'D3', 7, ['None'], 1, '<0,0,0>', 'D3', 7, ['None'], 11, '<e,0.57735*e,f>', 'D6', 'P6322', 3, '(2*e, 2*e, 4*f), (90, 90, 120)', 2, 2],
108: [108, 'D3', 7, ['None'], 4, '<e,e,e>', 'D3', 7, ['None'], 12, '<e,3*e,e>', 'O', 'P4232', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 2],
109: [109, 'D3', 7, ['None'], 4, '<3*e,3*e,3*e>', 'D3', 7, ['None'], 12, '<e,3*e,5*e>', 'O', 'P4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 1, 1],
110: [110, 'D3', 7, ['None'], 4, '<e,e,e>', 'D4', 8, ['None'], 1, '<0,0,2*e>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 2],
111: [111, 'D3', 7, ['None'], 11, '<e,0.57735*e,0>', 'D6', 9, ['None'], 1, '<0,0,0>', 'D6', 'p622', 2, '(2*e, 2*e), 120', 1, 1],
112: [112, 'D3', 7, ['None'], 11, '<e,0.57735*e,f>', 'D6', 9, ['None'], 1, '<0,0,0>', 'D6', 'P622', 3, '(2*e, 2*e, 2*f), (90, 90, 120)', 2, 2],
113: [113, 'D3', 7, ['None'], 4, '<e,e,e>', 'T', 10, ['None'], 1, '<0,0,0>', 'O', 'F4132', 3, '(8*e, 8*e, 8*e), (90, 90, 90)', 1, 1],
114: [114, 'D3', 7, ['None'], 4, '<e,e,e>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'I432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 1],
115: [115, 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 8, ['None'], 1, '<e,e,0>', 'D4', 'p422', 2, '(2*e, 2*e), 90', 1, 1],
116: [116, 'D4', 8, ['None'], 1, '<0,0,0>', 'D4', 8, ['None'], 1, '<e,e,f>', 'D4', 'P422', 3, '(2*e, 2*e, 2*f), (90, 90,90)', 2, 2],
117: [117, 'D4', 8, ['None'], 1, '<0,0,e>', 'D4', 8, ['None'], 2, '<0,e,e>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 1, 1],
118: [118, 'D4', 8, ['None'], 1, '<0,0,e>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 1, 1],
119: [119, 'D4', 8, ['None'], 1, '<e,e,0>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 1, 1],
120: [120, 'T', 10, ['None'], 1, '<0,0,0>', 'T', 10, ['None'], 1, '<e,e,e>', 'T', 'F23', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 1],
121: [121, 'T', 10, ['None'], 1, '<0,0,0>', 'T', 10, ['None'], 1, '<e,0,0>', 'T', 'F23', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 1, 1],
122: [122, 'T', 10, ['None'], 1, '<e,e,e>', 'O', 11, ['None'], 1, '<0,0,0>', 'O', 'F432', 3, '(4*e, 4*e, 4*e), (90, 90, 90)', 1, 1],
123: [123, 'O', 11, ['None'], 1, '<0,0,0>', 'O', 11, ['None'], 1, '<e,e,e>', 'O', 'P432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 1, 1],
124: [124, 'O', 11, ['None'], 1, '<0,0,0>', 'O', 11, ['None'], 1, '<e,0,0>', 'O', 'F432', 3, '(2*e, 2*e, 2*e), (90, 90, 90)', 1, 1]}
# ROTATION RANGE DEG
C2 = 180
C3 = 120
C4 = 90
C5 = 72
C6 = 60
RotRangeDict = {"C2": C2, "C3": C3, "C4": C4, "C5": C5, "C6": C6}
# ROTATION SETTING MATRICES
RotMat1 = [[1.0, 0.0, 0.0], [0.0, 1.0, 0.0], [0.0, 0.0, 1.0]]
RotMat2 = [[0.0, 0.0, 1.0], [0.0, 1.0, 0.0], [-1.0, 0.0, 0.0]]
RotMat3 = [[0.707107, 0.0, 0.707107], [0.0, 1.0, 0.0], [-0.707107, 0.0, 0.707107]]
RotMat4 = [[0.707107, 0.408248, 0.577350], [-0.707107, 0.408248, 0.577350], [0.0, -0.816497, 0.577350]]
RotMat5 = [[0.707107, 0.707107, 0.0], [-0.707107, 0.707107, 0.0], [0.0, 0.0, 1.0]]
RotMat6 = [[1.0, 0.0, 0.0], [0.0, 0.0, 1.0], [0.0, -1.0, 0.0]]
RotMat7 = [[1.0, 0.0, 0.0], [0.0, 0.934172, 0.356822], [0.0, -0.356822, 0.934172]]
RotMat8 = [[0.0, 0.707107, 0.707107], [0.0, -0.707107, 0.707107], [1.0, 0.0, 0.0]]
RotMat9 = [[0.850651, 0.0, 0.525732], [0.0, 1.0, 0.0], [-0.525732, 0.0, 0.850651]]
RotMat10 = [[0.0, 0.5, 0.866025], [0.0, -0.866025, 0.5], [1.0, 0.0, 0.0]]
RotMat11 = [[0.0, -1.0, 0.0], [1.0, 0.0, 0.0], [0.0, 0.0, 1.0]]
RotMat12 = [[0.707107, -0.408248, 0.577350], [0.707107, 0.408248, -0.577350], [0.0, 0.816497, 0.577350]]
RotMat13 = [[0.5, -0.866025, 0.0], [0.866025, 0.5, 0.0], [0.0, 0.0, 1.0]]
RotSetDict = {1: RotMat1,
2: RotMat2,
3: RotMat3,
4: RotMat4,
5: RotMat5,
6: RotMat6,
7: RotMat7,
8: RotMat8,
9: RotMat9,
10: RotMat10,
11: RotMat11,
12: RotMat12,
13: RotMat13}
class SymEntry:
def __init__(self, entry):
if type(entry) == int and entry in range(1, 125):
# GETTING ENTRY INFORMATION FROM sym_comb_dict
self.entry_number = entry
sym_comb_info = sym_comb_dict[self.entry_number]
# ASSIGNING CLASS VARIABLES
self.group1 = sym_comb_info[1]
self.group1_indx = sym_comb_info[2]
self.int_dof_group1 = sym_comb_info[3]
self.rot_set_group1 = sym_comb_info[4]
self.ref_frame_tx_dof_group1 = sym_comb_info[5]
self.group2 = sym_comb_info[6]
self.group2_indx = sym_comb_info[7]
self.int_dof_group2 = sym_comb_info[8]
self.rot_set_group2 = sym_comb_info[9]
self.ref_frame_tx_dof_group2 = sym_comb_info[10]
self.pt_grp = sym_comb_info[11]
self.result = sym_comb_info[12]
self.dim = sym_comb_info[13]
self.unit_cell = sym_comb_info[14]
self.tot_dof = sym_comb_info[15]
self.cycle_size = sym_comb_info[16]
else:
raise ValueError("\nINVALID SYMMETRY ENTRY. SUPPORTED VALUES ARE: 1 to 124\n")
def get_group1_sym(self):
return self.group1
def get_group2_sym(self):
return self.group2
def get_pt_grp_sym(self):
return self.pt_grp
def get_rot_range_deg_1(self):
if self.group1 in RotRangeDict:
return RotRangeDict[self.group1]
else:
return 0
def get_rot_range_deg_2(self):
if self.group2 in RotRangeDict:
return RotRangeDict[self.group2]
else:
return 0
def get_rot_set_mat_group1(self):
return RotSetDict[self.rot_set_group1]
def get_ref_frame_tx_dof_group1(self):
return self.ref_frame_tx_dof_group1
def get_rot_set_mat_group2(self):
return RotSetDict[self.rot_set_group2]
def get_ref_frame_tx_dof_group2(self):
return self.ref_frame_tx_dof_group2
def get_result_design_sym(self):
return self.result
def get_design_dim(self):
return self.dim
def get_uc_spec_string(self):
return self.unit_cell
def is_internal_tx1(self):
if 't:<0,0,b>' in self.int_dof_group1:
return True
else:
return False
def is_internal_tx2(self):
if 't:<0,0,d>' in self.int_dof_group2:
return True
else:
return False
def get_internal_tx1(self):
if 't:<0,0,b>' in self.int_dof_group1:
return 't:<0,0,b>'
else:
return None
def get_internal_tx2(self):
if 't:<0,0,d>' in self.int_dof_group2:
return 't:<0,0,d>'
else:
return None
def is_internal_rot1(self):
if 'r:<0,0,1,a>' in self.int_dof_group1:
return True
else:
return False
def is_internal_rot2(self):
if 'r:<0,0,1,c>' in self.int_dof_group2:
return True
else:
return False
def get_internal_rot1(self):
if 'r:<0,0,1,a>' in self.int_dof_group1:
return 'r:<0,0,1,a>'
else:
return None
def get_internal_rot2(self):
if 'r:<0,0,1,c>' in self.int_dof_group2:
return 'r:<0,0,1,c>'
else:
return None
def is_ref_frame_tx_dof1(self):
if self.ref_frame_tx_dof_group1 != '<0,0,0>':
return True
else:
return False
def is_ref_frame_tx_dof2(self):
if self.ref_frame_tx_dof_group2 != '<0,0,0>':
return True
else:
return False
|
class Node:
def __init__(self, data):
self.data = data
self.next = None
class LinkedList:
def __init__(self):
self.size = 0
self.head = None
self.last = None
def get(self, index):
if index < 0 or index >= self.size:
raise Exception("超出链表节点范围!")
p = self.head
for i in range(index):
p = p.next
return p
def insert(self, data, index):
if index < 0 or index > self.size:
raise Exception("超出链表节点范围!")
node = Node(data)
if self.size == 0:
# 空链表
self.head = node
self.last = node
elif index == 0:
# 插入头部
node.next = self.head
self.head = node
elif self.size == index:
# 插入尾部
self.last.next = node
self.last = node
else:
# 插入中间
prev_node = self.get(index-1)
node.next = prev_node.next
prev_node.next = node
self.size += 1
def remove(self, index):
if index < 0 or index >= self.size:
raise Exception("超出链表节点范围!")
# 暂存被删除的节点,用于返回
if index == 0:
# 删除头节点
removed_node = self.head
self.head = self.head.next
if self.size == 1:
self.last == Node
elif index == self.size - 1:
# 删除尾节点
prev_node = self.get(index-1)
removed_node = prev_node.next
prev_node.next = None
self.last = prev_node
else:
# 删除中间节点
prev_node = self.get(index-1)
next_node = prev_node.next.next
removed_node = prev_node.next
prev_node.next = next_node
self.size -= 1
return removed_node
def output(self):
p = self.head
while p is not None:
print(p.data)
p = p.next
linkedList = LinkedList()
linkedList.insert(3, 0)
linkedList.insert(4, 0)
linkedList.insert(9, 2)
linkedList.insert(5, 3)
linkedList.insert(6, 1)
linkedList.remove(0)
linkedList.output()
|
# -*- coding:utf-8 -*-
'''
User defined Configuration for the application.
'''
DB_CFG = {
'db': 'maplet',
'user': 'maplet',
'pass': '131322',
}
SMTP_CFG = {
'name': '云算笔记',
'host': "smtp.ym.163.com",
'user': "admin@yunsuan.org",
'pass': "pass",
'postfix': 'yunsuan.org',
}
SITE_CFG = {
'site_url': 'http://127.0.0.1:8777',
'cookie_secret': 'sadfasdf',
'DEBUG': True,
'wcs': 'wcs.osgeo.cn'
}
ROLE_CFG = {
'add': '1000',
'edit': '2000',
'delete': '3000',
}
|
#pydoc - generate automat documentation
class Saludos:
"""
Esta es la documentación de la clase silla
Tendra dos funciones buenos_dias y adios
y ambas será necesario pasarle un parametro con el nombre de la persona
"""
def buenos_dias(self, nombre):
""" Sirve para dar los buenos días a un nombre pasado como parametro"""
print("Buenos días {}".format(nombre))
def adios(self, nombre):
""" Sirve para decir adios a un nombre pasado como parametro"""
print("Adios {}".format(nombre))
|
n, k = map(int, input().split())
y = sorted(map(int, input().split()))
sol = 0
for i in y:
if k <= (5-i):
sol += 1
print(sol//3)
|
# Enter your code here. Read input from STDIN. Print output to STDOUT
#with name and number input, divide both and enter into dict
phonebook = {}
number = int(input())
for _ in range(0, number):
item = str(input()).split(" ")
name = item[0]
phonenumber = int(item[1])
phonebook[name] = phonenumber
#check if name already in dict
for i in range(0, number):
name = input()
if name in phonebook:
print(name + "=" + str(phonebook[name]))
else:
print("Not found")
#the above code gave runtime error on test case 1
# Enter your code here. Read input from STDIN. Print output to STDOUT
#with name and number input, divide both and enter into dict
phonebook = {}
number = int(input())
for i in range(number):
text = input().split()
phonebook[text[0]] = text[1]
#check if name already in dict
while True:
try:
entry = input()
if entry in phonebook:
print(entry+"="+phonebook[entry])
else:
print("Not found")
except EOFError:
break
#so what's the difference?
|
{
"targets":[
{
"target_name":"pcap_addon",
"sources":[
"./src/winpcap/pcap_addon.cc",
"./src/winpcap/pcapObjFactory.cc",
"./src/winpcap/commLib.cc"],
"include_dirs": [
"<!(node -e \"require('nan')\")",
"lib/winpcap/include",
"lib/winpcap/include/pcap",
"src/winpcap/include"
],
"defines":[
"HAVE_REMOTE"
],
"conditions":[
["OS==\"win\"", {
"conditions":[
['target_arch=="x64"',{
"libraries": [
"-l../lib/winpcap/lib/x64/wpcap",
"-l../lib/winpcap/lib/x64/Packet"
]
}],
['target_arch=="x86"',{
"libraries": [
"-l../lib/winpcap/lib/wpcap",
"-l../lib/winpcap/lib/Packet"
]
}]
]
}],
["OS==\"linux\"", {
"libraries": [
"lib/winpcap/Lib/libwpcap.a",
"lib/winpcap/Lib/libpacket.a"
]
}]
]
}
]
}
|
# Program: impostos_exemplo1.py
# Author: Ramon R. Valeriano
# Description: Todas as funções, metodos para se calculos os impostos
# Developed: 16/04/2021 - 21:13
# Updated: 16/04/2021 - 21:23 - Vamos deixar nossos orientado a objetos
class ISS:
def calcula(self, orcamento):
return orcamento.valor * 0.1
class ICMS:
def calcula(self, orcamento):
return orcamento.valor * 0.06
|
# coding: utf-8
# file generated by setuptools_scm
# don't change, don't track in version control
version = '1.9.0'
version_tuple = (1, 9, 0)
|
# -*- coding: utf-8 -*-
"""
Generate features from pandas dataframe, with columns statistics.
-------------------
Return dataframe, columns=[by, col]
"""
def get_count(df, by):
return df.groupby(by=by).count().iloc[:,0]
def get_sum(df, col, by):
return df.groupby(by=by).sum()[col]
def get_mean(df, col, by):
return df.groupby(by=by).mean()[col]
def get_std(df, col, by):
return df.groupby(by=by).std()[col]
def get_max(df, col, by):
return df.groupby(by=by).max()[col]
def get_min(df, col, by):
return df.groupby(by=by).min()[col]
def get_dum_sum(df, col, prefix, by, drop_first=False):
return pd.get_dummies(df[by + col], columns=col, prefix=prefix, drop_first=drop_first).groupby(by).sum()
def get_dum_has(df, col, prefix, by, drop_first=False):
return pd.get_dummies(df[by + col], columns=col, prefix=prefix, drop_first=drop_first).groupby(by).max()
|
LINKING_PROPERTY = "Transaction/generated/LinkedTransactionId"
INPUT_TXN_FILTER = "type in 'Buy','Purchase','Sell','FwdFxSell', 'FwdFxBuy','FxBuy','FxSell','StockIn'"
ENTITY_PROPERTY = "Portfolio/test/Entity"
BROKER_PROPERTY = "Portfolio/test/Broker"
COUNTRY_PROPERTY = "Instrument/test/Country"
PROPERTIES_REQUIRED = [
ENTITY_PROPERTY,
BROKER_PROPERTY,
COUNTRY_PROPERTY
]
|
"""
Given a lowercase string, s, return the index fo the first character that appears just once in a string.
If every character appears more than once, return -1
Example input:
s: "Who wants hot watermelon?"
Example Output:
8
Explanation:
"who wants hot watermelon?"
^
012345678
The first charactter that appears only once is "s" and it appears at index 8.
"""
def solution(s):
# Type your solution here
has_been_seen = {}
for i in range(len(s)):
if s[i] not in has_been_seen:
has_been_seen[s[i]] = 0
has_been_seen[s[i]] += 1
for i in range(len(s)):
if has_been_seen[s[i]] == 1:
return i
return -1
if __name__ == '__main__':
s = "who wants hot watermelon?"
print(solution(s=s))
|
class Solution:
def reformatNumber(self, number: str) -> str:
number = number.replace(' ','')
number = number.replace('-','')
output = ''
count = len(number)
remain = count % 3
print(remain)
if remain == 0:
last = number[len(number)-3:]
end = len(number)-3
if remain == 2:
last = number[len(number)-2:]
end = len(number)-2
if remain == 1:
last = number[len(number)-4:len(number)-2] + '-' + number[len(number)-2:]
end = len(number)-4
for i,num in enumerate(number[:end]):
output += num
if (i+1)%3 == 0:
output += '-'
count -= 1
output += last
return output
|
numero = int(input('digite um numero: '))
u = numero // 1 % 10
d = numero // 10 % 10
c = numero // 100 % 10
m = numero // 1000 % 10
print('analisando numero {}'.format(numero))
print('unidades: {}'.format(u))
print('dezenas: {}'.format(d))
print('centenas: {}'.format(c))
print('milhares: {}'.format(m))
|
SOURCE = "http://tabinstore.fr"
HEADER = "User-Agent: Mozilla/5.0 (Windows NT 6.0) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.97 Safari/537.11"
MAX_IMG_SIZE = 71680 # In Bytes
|
"""
Exercício Python 034:
Escreva um programa que pergunte o salário de um funcionário e calcule o valor do seu aumento.
Para salários superiores a R$1.250,00, calcule um aumento de 10%.
Para os inferiores ou iguais, o aumento é de 15%.
"""
print('=-' * 10, 'Desafio 34', '-=' * 10)
salario = float(input('Qual o atual salário do funcionário? R$'))
if salario > 1.250:
print('Será atribuído uma aumento de 10% ao valor de R${:.3f}. O salário atualizado será de {:.3f}.'.format(salario, salario + (salario * 10 / 100)))
else:
print('Será atribuído uma aumento de 15% ao valor de R${:.3f}. O salário atualizado será de {:.3f}.'.format(salario, salario + (salario * 15 / 100)))
|
print('=' * 30)
print('{:^30}'.format('Expressão'))
print('=' * 30)
print('')
e = str(input("Digite sua expressão: ")).strip()
p1 = e.count("(")
p2 = e.count(")")
if p1 == p2:
print("Sua expressão está correta !")
else:
print("Sua expressão está incorreta !")
|
li = []
inp = input()
li = inp.split(' ' , 5)
print(1-int(li[0]),' ',1-int(li[1]),' ',2-int(li[2]),' ',2-int(li[3]),' ',2-int(li[4]),' ',8-int(li[5]), end = '')
|
# Ternary numeric notation is quite popular in Berland. To telegraph the ternary number the Borze alphabet is used. Digit 0 is transmitted as «.», 1 as «-.» and 2 as «--». You are to decode the Borze code, i.e. to find out the ternary number given its representation in Borze alphabet.
# Input
# The first line contains a number in Borze code. The length of the string is between 1 and 200 characters. It's guaranteed that the given string is a valid Borze code of some ternary number (this number can have leading zeroes).
# Output
# Output the decoded ternary number. It can have leading zeroes.
# input
# .-.--
# output
# 012
# input
# --.
# output
# 20
# input
# -..-.--
# output
# 1012
s = input() #input the string
size = len(s) # it calculate the size of the input string
i = 0 # pointed at starting of the string
j = i+1
string = "" #empty string
while j < len(s): # this loop works till j == size of the input string(s)
if s[i] == ".":
string += "0"
i = j
j = i+1
elif s[i] == "-" and s[j] == ".":
string += "1"
i = j+1
j = i+1
elif s[i] == "-" and s[j] == "-":
string += "2"
i = j+1
j = i+1
while i < len(s):
if s[i] == ".":
string += "0"
i+=1
print(string)
|
x,y = 8, 4
if x > y:
print("x es mayor que y")
print("x es el doble de y")
if x > y:
print("x es mayor que y")
else:
print("x es menor o igual que y")
if x < y:
print("x es menor que y")
elif x == y:
print("x es igual a y")
else:
print("x es mayor que y")
|
set_name(0x8012EA14, "GameOnlyTestRoutine__Fv", SN_NOWARN)
set_name(0x8012EA1C, "vecleny__Fii", SN_NOWARN)
set_name(0x8012EA40, "veclenx__Fii", SN_NOWARN)
set_name(0x8012EA6C, "GetDamageAmt__FiPiT1", SN_NOWARN)
set_name(0x8012F0DC, "CheckBlock__Fiiii", SN_NOWARN)
set_name(0x8012F22C, "FindClosest__Fiii", SN_NOWARN)
set_name(0x8012F3C8, "GetSpellLevel__Fii", SN_NOWARN)
set_name(0x8012F49C, "GetDirection8__Fiiii", SN_NOWARN)
set_name(0x8012F6B8, "DeleteMissile__Fii", SN_NOWARN)
set_name(0x8012F778, "GetMissileVel__Fiiiiii", SN_NOWARN)
set_name(0x8012F8FC, "PutMissile__Fi", SN_NOWARN)
set_name(0x8012FA38, "GetMissilePos__Fi", SN_NOWARN)
set_name(0x8012FB88, "MoveMissilePos__Fi", SN_NOWARN)
set_name(0x8012FD10, "MonsterTrapHit__FiiiiiUc", SN_NOWARN)
set_name(0x801300D0, "MonsterMHit__FiiiiiiUc", SN_NOWARN)
set_name(0x801308AC, "PlayerMHit__FiiiiiiUcUc", SN_NOWARN)
set_name(0x8013133C, "Plr2PlrMHit__FiiiiiiUc", SN_NOWARN)
set_name(0x80131B3C, "CheckMissileCol__FiiiUciiUc", SN_NOWARN)
set_name(0x801322B8, "SetMissAnim__Fii", SN_NOWARN)
set_name(0x801323A8, "SetMissDir__Fii", SN_NOWARN)
set_name(0x80132420, "AddLArrow__Fiiiiiicii", SN_NOWARN)
set_name(0x80132620, "AddArrow__Fiiiiiicii", SN_NOWARN)
set_name(0x801327FC, "GetVileMissPos__Fiii", SN_NOWARN)
set_name(0x8013293C, "AddRndTeleport__Fiiiiiicii", SN_NOWARN)
set_name(0x80132CDC, "AddFirebolt__Fiiiiiicii", SN_NOWARN)
set_name(0x80132FBC, "AddMagmaball__Fiiiiiicii", SN_NOWARN)
set_name(0x801330F0, "AddTeleport__Fiiiiiicii", SN_NOWARN)
set_name(0x8013335C, "AddLightball__Fiiiiiicii", SN_NOWARN)
set_name(0x801334D0, "AddFirewall__Fiiiiiicii", SN_NOWARN)
set_name(0x801336D4, "AddFireball__Fiiiiiicii", SN_NOWARN)
set_name(0x8013394C, "AddLightctrl__Fiiiiiicii", SN_NOWARN)
set_name(0x80133A54, "AddLightning__Fiiiiiicii", SN_NOWARN)
set_name(0x80133C4C, "AddMisexp__Fiiiiiicii", SN_NOWARN)
set_name(0x80133EC0, "CheckIfTrig__Fii", SN_NOWARN)
set_name(0x80133FCC, "AddTown__Fiiiiiicii", SN_NOWARN)
set_name(0x8013442C, "AddFlash__Fiiiiiicii", SN_NOWARN)
set_name(0x8013465C, "AddFlash2__Fiiiiiicii", SN_NOWARN)
set_name(0x80134870, "AddManashield__Fiiiiiicii", SN_NOWARN)
set_name(0x80134970, "AddFiremove__Fiiiiiicii", SN_NOWARN)
set_name(0x80134AE8, "AddGuardian__Fiiiiiicii", SN_NOWARN)
set_name(0x80134FD0, "AddChain__Fiiiiiicii", SN_NOWARN)
set_name(0x80135068, "AddRhino__Fiiiiiicii", SN_NOWARN)
set_name(0x801352C8, "AddFlare__Fiiiiiicii", SN_NOWARN)
set_name(0x801355E0, "AddAcid__Fiiiiiicii", SN_NOWARN)
set_name(0x80135704, "AddAcidpud__Fiiiiiicii", SN_NOWARN)
set_name(0x801357FC, "AddStone__Fiiiiiicii", SN_NOWARN)
set_name(0x80135B48, "AddGolem__Fiiiiiicii", SN_NOWARN)
set_name(0x80135D4C, "AddBoom__Fiiiiiicii", SN_NOWARN)
set_name(0x80135E34, "AddHeal__Fiiiiiicii", SN_NOWARN)
set_name(0x8013607C, "AddHealOther__Fiiiiiicii", SN_NOWARN)
set_name(0x8013610C, "AddElement__Fiiiiiicii", SN_NOWARN)
set_name(0x80136354, "AddIdentify__Fiiiiiicii", SN_NOWARN)
set_name(0x80136424, "AddFirewallC__Fiiiiiicii", SN_NOWARN)
set_name(0x80136700, "AddInfra__Fiiiiiicii", SN_NOWARN)
set_name(0x80136830, "AddWave__Fiiiiiicii", SN_NOWARN)
set_name(0x801368B4, "AddNova__Fiiiiiicii", SN_NOWARN)
set_name(0x80136AEC, "AddRepair__Fiiiiiicii", SN_NOWARN)
set_name(0x80136BBC, "AddRecharge__Fiiiiiicii", SN_NOWARN)
set_name(0x80136C8C, "AddDisarm__Fiiiiiicii", SN_NOWARN)
set_name(0x80136D1C, "AddApoca__Fiiiiiicii", SN_NOWARN)
set_name(0x80136F7C, "AddFlame__Fiiiiiicii", SN_NOWARN)
set_name(0x801371F8, "AddFlamec__Fiiiiiicii", SN_NOWARN)
set_name(0x80137308, "AddCbolt__Fiiiiiicii", SN_NOWARN)
set_name(0x80137520, "AddHbolt__Fiiiiiicii", SN_NOWARN)
set_name(0x80137700, "AddResurrect__Fiiiiiicii", SN_NOWARN)
set_name(0x80137794, "AddResurrectBeam__Fiiiiiicii", SN_NOWARN)
set_name(0x8013786C, "AddTelekinesis__Fiiiiiicii", SN_NOWARN)
set_name(0x801378FC, "AddBoneSpirit__Fiiiiiicii", SN_NOWARN)
set_name(0x80137B14, "AddRportal__Fiiiiiicii", SN_NOWARN)
set_name(0x80137BF8, "AddDiabApoca__Fiiiiiicii", SN_NOWARN)
set_name(0x80137D54, "AddMissile__Fiiiiiiciii", SN_NOWARN)
set_name(0x801380A8, "Sentfire__Fiii", SN_NOWARN)
set_name(0x801382A8, "MI_Dummy__Fi", SN_NOWARN)
set_name(0x801382B0, "MI_Golem__Fi", SN_NOWARN)
set_name(0x8013852C, "MI_SetManashield__Fi", SN_NOWARN)
set_name(0x80138568, "MI_LArrow__Fi", SN_NOWARN)
set_name(0x80138D44, "MI_Arrow__Fi", SN_NOWARN)
set_name(0x80138F78, "MI_Firebolt__Fi", SN_NOWARN)
set_name(0x80139660, "MI_Lightball__Fi", SN_NOWARN)
set_name(0x80139904, "MI_Acidpud__Fi", SN_NOWARN)
set_name(0x80139A34, "MI_Firewall__Fi", SN_NOWARN)
set_name(0x80139D18, "MI_Fireball__Fi", SN_NOWARN)
set_name(0x8013A6F8, "MI_Lightctrl__Fi", SN_NOWARN)
set_name(0x8013ACA8, "MI_Lightning__Fi", SN_NOWARN)
set_name(0x8013AE40, "MI_Town__Fi", SN_NOWARN)
set_name(0x8013B104, "MI_Flash__Fi", SN_NOWARN)
set_name(0x8013B534, "MI_Flash2__Fi", SN_NOWARN)
set_name(0x8013B774, "MI_Manashield__Fi", SN_NOWARN)
set_name(0x8013BD98, "MI_Firemove__Fi", SN_NOWARN)
set_name(0x8013C1F4, "MI_Guardian__Fi", SN_NOWARN)
set_name(0x8013C5E0, "MI_Chain__Fi", SN_NOWARN)
set_name(0x8013C904, "MI_Misexp__Fi", SN_NOWARN)
set_name(0x8013CC24, "MI_Acidsplat__Fi", SN_NOWARN)
set_name(0x8013CDE8, "MI_Teleport__Fi", SN_NOWARN)
set_name(0x8013D1D0, "MI_Stone__Fi", SN_NOWARN)
set_name(0x8013D398, "MI_Boom__Fi", SN_NOWARN)
set_name(0x8013D4AC, "MI_Rhino__Fi", SN_NOWARN)
set_name(0x8013D894, "MI_FirewallC__Fi", SN_NOWARN)
set_name(0x8013DC88, "MI_Infra__Fi", SN_NOWARN)
set_name(0x8013DD68, "MI_Apoca__Fi", SN_NOWARN)
set_name(0x8013E01C, "MI_Wave__Fi", SN_NOWARN)
set_name(0x8013E5C4, "MI_Nova__Fi", SN_NOWARN)
set_name(0x8013E8A4, "MI_Flame__Fi", SN_NOWARN)
set_name(0x8013EAB8, "MI_Flamec__Fi", SN_NOWARN)
set_name(0x8013EDE8, "MI_Cbolt__Fi", SN_NOWARN)
set_name(0x8013F10C, "MI_Hbolt__Fi", SN_NOWARN)
set_name(0x8013F438, "MI_Element__Fi", SN_NOWARN)
set_name(0x8013FB0C, "MI_Bonespirit__Fi", SN_NOWARN)
set_name(0x8013FF30, "MI_ResurrectBeam__Fi", SN_NOWARN)
set_name(0x8013FFC8, "MI_Rportal__Fi", SN_NOWARN)
set_name(0x8014020C, "ProcessMissiles__Fv", SN_NOWARN)
set_name(0x80140600, "ClearMissileSpot__Fi", SN_NOWARN)
set_name(0x801406F0, "MoveToScrollTarget__7CBlocks", SN_NOWARN)
set_name(0x80140704, "MonstPartJump__Fi", SN_NOWARN)
set_name(0x80140898, "DeleteMonster__Fi", SN_NOWARN)
set_name(0x80140930, "M_GetDir__Fi", SN_NOWARN)
set_name(0x801409B4, "M_StartDelay__Fii", SN_NOWARN)
set_name(0x80140A40, "M_StartRAttack__Fiii", SN_NOWARN)
set_name(0x80140BA4, "M_StartRSpAttack__Fiii", SN_NOWARN)
set_name(0x80140D14, "M_StartSpAttack__Fi", SN_NOWARN)
set_name(0x80140E48, "M_StartEat__Fi", SN_NOWARN)
set_name(0x80140F64, "M_GetKnockback__Fi", SN_NOWARN)
set_name(0x801411C0, "M_StartHit__Fiii", SN_NOWARN)
set_name(0x801414F0, "M_DiabloDeath__FiUc", SN_NOWARN)
set_name(0x80141838, "M2MStartHit__Fiii", SN_NOWARN)
set_name(0x80141B28, "MonstStartKill__FiiUc", SN_NOWARN)
set_name(0x80141E40, "M2MStartKill__Fii", SN_NOWARN)
set_name(0x80142260, "M_StartKill__Fii", SN_NOWARN)
set_name(0x80142370, "M_StartFadein__FiiUc", SN_NOWARN)
set_name(0x80142510, "M_StartFadeout__FiiUc", SN_NOWARN)
set_name(0x801426A4, "M_StartHeal__Fi", SN_NOWARN)
set_name(0x80142778, "M_ChangeLightOffset__Fi", SN_NOWARN)
set_name(0x80142840, "M_DoStand__Fi", SN_NOWARN)
set_name(0x801428F8, "M_DoWalk__Fi", SN_NOWARN)
set_name(0x80142BC4, "M_DoWalk2__Fi", SN_NOWARN)
set_name(0x80142DF8, "M_DoWalk3__Fi", SN_NOWARN)
set_name(0x80143104, "M_TryM2MHit__Fiiiii", SN_NOWARN)
set_name(0x80143314, "M_TryH2HHit__Fiiiii", SN_NOWARN)
set_name(0x80143B38, "M_DoAttack__Fi", SN_NOWARN)
set_name(0x80143D24, "M_DoRAttack__Fi", SN_NOWARN)
set_name(0x80143EDC, "M_DoRSpAttack__Fi", SN_NOWARN)
set_name(0x80144118, "M_DoSAttack__Fi", SN_NOWARN)
set_name(0x80144230, "M_DoFadein__Fi", SN_NOWARN)
set_name(0x80144328, "M_DoFadeout__Fi", SN_NOWARN)
set_name(0x80144494, "M_DoHeal__Fi", SN_NOWARN)
set_name(0x80144570, "M_DoTalk__Fi", SN_NOWARN)
set_name(0x80144A78, "M_Teleport__Fi", SN_NOWARN)
set_name(0x80144D14, "M_DoGotHit__Fi", SN_NOWARN)
set_name(0x80144DCC, "DoEnding__Fv", SN_NOWARN)
set_name(0x80144DD4, "PrepDoEnding__Fv", SN_NOWARN)
set_name(0x80144F30, "M_DoDeath__Fi", SN_NOWARN)
set_name(0x801451F4, "M_DoSpStand__Fi", SN_NOWARN)
set_name(0x801452DC, "M_DoDelay__Fi", SN_NOWARN)
set_name(0x80145414, "M_DoStone__Fi", SN_NOWARN)
set_name(0x801454D4, "M_WalkDir__Fii", SN_NOWARN)
set_name(0x80145750, "GroupUnity__Fi", SN_NOWARN)
set_name(0x80145B84, "M_CallWalk__Fii", SN_NOWARN)
set_name(0x80145D70, "M_PathWalk__Fi", SN_NOWARN)
set_name(0x80145E50, "M_CallWalk2__Fii", SN_NOWARN)
set_name(0x80145F64, "M_DumbWalk__Fii", SN_NOWARN)
set_name(0x80145FB8, "M_RoundWalk__FiiRi", SN_NOWARN)
set_name(0x80146158, "MAI_Zombie__Fi", SN_NOWARN)
set_name(0x8014636C, "MAI_SkelSd__Fi", SN_NOWARN)
set_name(0x80146520, "MAI_Snake__Fi", SN_NOWARN)
set_name(0x80146944, "MAI_Bat__Fi", SN_NOWARN)
set_name(0x80146D18, "MAI_SkelBow__Fi", SN_NOWARN)
set_name(0x80146F20, "MAI_Fat__Fi", SN_NOWARN)
set_name(0x801470F0, "MAI_Sneak__Fi", SN_NOWARN)
set_name(0x801474F8, "MAI_Fireman__Fi", SN_NOWARN)
set_name(0x8014780C, "MAI_Fallen__Fi", SN_NOWARN)
set_name(0x80147B44, "MAI_Cleaver__Fi", SN_NOWARN)
set_name(0x80147C48, "MAI_Round__FiUc", SN_NOWARN)
set_name(0x801480D4, "MAI_GoatMc__Fi", SN_NOWARN)
set_name(0x801480F4, "MAI_Ranged__FiiUc", SN_NOWARN)
set_name(0x80148338, "MAI_GoatBow__Fi", SN_NOWARN)
set_name(0x8014835C, "MAI_Succ__Fi", SN_NOWARN)
set_name(0x80148380, "MAI_AcidUniq__Fi", SN_NOWARN)
set_name(0x801483A4, "MAI_Scav__Fi", SN_NOWARN)
set_name(0x801487D8, "MAI_Garg__Fi", SN_NOWARN)
set_name(0x801489D8, "MAI_RoundRanged__FiiUciUc", SN_NOWARN)
set_name(0x80148F10, "MAI_Magma__Fi", SN_NOWARN)
set_name(0x80148F3C, "MAI_Storm__Fi", SN_NOWARN)
set_name(0x80148F68, "MAI_Acid__Fi", SN_NOWARN)
set_name(0x80148F98, "MAI_Diablo__Fi", SN_NOWARN)
set_name(0x80148FC4, "MAI_RR2__Fiii", SN_NOWARN)
set_name(0x801494E0, "MAI_Mega__Fi", SN_NOWARN)
set_name(0x80149504, "MAI_SkelKing__Fi", SN_NOWARN)
set_name(0x80149A5C, "MAI_Rhino__Fi", SN_NOWARN)
set_name(0x80149F20, "MAI_Counselor__Fi", SN_NOWARN)
set_name(0x8014A408, "MAI_Garbud__Fi", SN_NOWARN)
set_name(0x8014A5D4, "MAI_Zhar__Fi", SN_NOWARN)
set_name(0x8014A7E8, "MAI_SnotSpil__Fi", SN_NOWARN)
set_name(0x8014AA38, "MAI_Lazurus__Fi", SN_NOWARN)
set_name(0x8014ACCC, "MAI_Lazhelp__Fi", SN_NOWARN)
set_name(0x8014AE08, "MAI_Lachdanan__Fi", SN_NOWARN)
set_name(0x8014AFB4, "MAI_Warlord__Fi", SN_NOWARN)
set_name(0x8014B11C, "DeleteMonsterList__Fv", SN_NOWARN)
set_name(0x8014B268, "ProcessMonsters__Fv", SN_NOWARN)
set_name(0x8014B8B8, "DirOK__Fii", SN_NOWARN)
set_name(0x8014BD10, "PosOkMissile__Fii", SN_NOWARN)
set_name(0x8014BD78, "CheckNoSolid__Fii", SN_NOWARN)
set_name(0x8014BDBC, "LineClearF__FPFii_Uciiii", SN_NOWARN)
set_name(0x8014C044, "LineClear__Fiiii", SN_NOWARN)
set_name(0x8014C084, "LineClearF1__FPFiii_Uciiiii", SN_NOWARN)
set_name(0x8014C318, "M_FallenFear__Fii", SN_NOWARN)
set_name(0x8014C50C, "PrintMonstHistory__Fi", SN_NOWARN)
set_name(0x8014C734, "PrintUniqueHistory__Fv", SN_NOWARN)
set_name(0x8014C858, "MissToMonst__Fiii", SN_NOWARN)
set_name(0x8014CD40, "PosOkMonst2__Fiii", SN_NOWARN)
set_name(0x8014CF5C, "PosOkMonst3__Fiii", SN_NOWARN)
set_name(0x8014D250, "M_SpawnSkel__Fiii", SN_NOWARN)
set_name(0x8014D3CC, "TalktoMonster__Fi", SN_NOWARN)
set_name(0x8014D50C, "SpawnGolum__Fiiii", SN_NOWARN)
set_name(0x8014D7A4, "CanTalkToMonst__Fi", SN_NOWARN)
set_name(0x8014D814, "CheckMonsterHit__FiRUc", SN_NOWARN)
set_name(0x8014D924, "MAI_Golum__Fi", SN_NOWARN)
set_name(0x8014DCB4, "MAI_Path__Fi", SN_NOWARN)
set_name(0x8014DE34, "M_StartAttack__Fi", SN_NOWARN)
set_name(0x8014DF68, "M_StartWalk__Fiiiiii", SN_NOWARN)
set_name(0x8014E194, "AddWarpMissile__Fiii", SN_NOWARN)
set_name(0x8014E29C, "SyncPortals__Fv", SN_NOWARN)
set_name(0x8014E3A4, "AddInTownPortal__Fi", SN_NOWARN)
set_name(0x8014E3E0, "ActivatePortal__FiiiiiUc", SN_NOWARN)
set_name(0x8014E4BC, "DeactivatePortal__Fi", SN_NOWARN)
set_name(0x8014E514, "PortalOnLevel__Fi", SN_NOWARN)
set_name(0x8014E584, "RemovePortalMissile__Fi", SN_NOWARN)
set_name(0x8014E720, "SetCurrentPortal__Fi", SN_NOWARN)
set_name(0x8014E72C, "GetPortalLevel__Fv", SN_NOWARN)
set_name(0x8014E91C, "GetPortalLvlPos__Fv", SN_NOWARN)
set_name(0x8014EA00, "FreeInvGFX__Fv", SN_NOWARN)
set_name(0x8014EA08, "InvDrawSlot__Fiii", SN_NOWARN)
set_name(0x8014EA8C, "InvDrawSlotBack__FiiiiUc", SN_NOWARN)
set_name(0x8014ECE0, "InvDrawItem__FiiiUci", SN_NOWARN)
set_name(0x8014EDB0, "InvDrawSlots__Fv", SN_NOWARN)
set_name(0x8014F0C4, "PrintStat__FiiPcUc", SN_NOWARN)
set_name(0x8014F190, "DrawInvStats__Fv", SN_NOWARN)
set_name(0x8014FD1C, "DrawInvBack__Fv", SN_NOWARN)
set_name(0x8014FDA4, "DrawInvCursor__Fv", SN_NOWARN)
set_name(0x80150280, "DrawInvMsg__Fv", SN_NOWARN)
set_name(0x80150448, "DrawInv__Fv", SN_NOWARN)
set_name(0x80150478, "DrawInvTSK__FP4TASK", SN_NOWARN)
set_name(0x80150744, "DoThatDrawInv__Fv", SN_NOWARN)
set_name(0x80151020, "AutoPlace__FiiiiUc", SN_NOWARN)
set_name(0x8015133C, "SpecialAutoPlace__FiiiiUc", SN_NOWARN)
set_name(0x801516D4, "GoldAutoPlace__Fi", SN_NOWARN)
set_name(0x80151BA0, "WeaponAutoPlace__Fi", SN_NOWARN)
set_name(0x80151E28, "SwapItem__FP10ItemStructT0", SN_NOWARN)
set_name(0x80151F18, "CheckInvPaste__Fiii", SN_NOWARN)
set_name(0x80153BA4, "CheckInvCut__Fiii", SN_NOWARN)
set_name(0x80154630, "RemoveInvItem__Fii", SN_NOWARN)
set_name(0x801548D4, "RemoveSpdBarItem__Fii", SN_NOWARN)
set_name(0x801549D4, "CheckInvScrn__Fv", SN_NOWARN)
set_name(0x80154A4C, "CheckItemStats__Fi", SN_NOWARN)
set_name(0x80154AD0, "CheckBookLevel__Fi", SN_NOWARN)
set_name(0x80154C04, "CheckQuestItem__Fi", SN_NOWARN)
set_name(0x8015502C, "InvGetItem__Fii", SN_NOWARN)
set_name(0x80155324, "AutoGetItem__Fii", SN_NOWARN)
set_name(0x80155D88, "FindGetItem__FiUsi", SN_NOWARN)
set_name(0x80155E3C, "SyncGetItem__FiiiUsi", SN_NOWARN)
set_name(0x80156048, "TryInvPut__Fv", SN_NOWARN)
set_name(0x80156210, "InvPutItem__Fiii", SN_NOWARN)
set_name(0x801566B4, "SyncPutItem__FiiiiUsiUciiiiiUl", SN_NOWARN)
set_name(0x80156C50, "CheckInvHLight__Fv", SN_NOWARN)
set_name(0x80156F94, "RemoveScroll__Fi", SN_NOWARN)
set_name(0x80157178, "UseScroll__Fv", SN_NOWARN)
set_name(0x801573E0, "UseStaffCharge__Fi", SN_NOWARN)
set_name(0x801574A0, "UseStaff__Fv", SN_NOWARN)
set_name(0x80157560, "StartGoldDrop__Fv", SN_NOWARN)
set_name(0x80157664, "UseInvItem__Fii", SN_NOWARN)
set_name(0x80157B8C, "DoTelekinesis__Fv", SN_NOWARN)
set_name(0x80157CB4, "CalculateGold__Fi", SN_NOWARN)
set_name(0x80157DEC, "DropItemBeforeTrig__Fv", SN_NOWARN)
set_name(0x80157E44, "ControlInv__Fv", SN_NOWARN)
set_name(0x801581CC, "InvGetItemWH__Fi", SN_NOWARN)
set_name(0x801582C4, "InvAlignObject__Fv", SN_NOWARN)
set_name(0x80158478, "InvSetItemCurs__Fv", SN_NOWARN)
set_name(0x8015860C, "InvMoveCursLeft__Fv", SN_NOWARN)
set_name(0x801587E8, "InvMoveCursRight__Fv", SN_NOWARN)
set_name(0x80158B00, "InvMoveCursUp__Fv", SN_NOWARN)
set_name(0x80158CE8, "InvMoveCursDown__Fv", SN_NOWARN)
set_name(0x80159000, "DumpMonsters__7CBlocks", SN_NOWARN)
set_name(0x80159028, "Flush__4CPad", SN_NOWARN)
set_name(0x8015904C, "SetRGB__6DialogUcUcUc", SN_NOWARN)
set_name(0x8015906C, "SetBack__6Dialogi", SN_NOWARN)
set_name(0x80159074, "SetBorder__6Dialogi", SN_NOWARN)
set_name(0x8015907C, "SetOTpos__6Dialogi", SN_NOWARN)
set_name(0x80159088, "___6Dialog", SN_NOWARN)
set_name(0x801590B0, "__6Dialog", SN_NOWARN)
set_name(0x8015910C, "StartAutomap__Fv", SN_NOWARN)
set_name(0x80159124, "AutomapUp__Fv", SN_NOWARN)
set_name(0x8015913C, "AutomapDown__Fv", SN_NOWARN)
set_name(0x80159154, "AutomapLeft__Fv", SN_NOWARN)
set_name(0x8015916C, "AutomapRight__Fv", SN_NOWARN)
set_name(0x80159184, "AMGetLine__FUcUcUc", SN_NOWARN)
set_name(0x80159230, "AmDrawLine__Fiiii", SN_NOWARN)
set_name(0x80159298, "DrawAutomapPlr__Fv", SN_NOWARN)
set_name(0x80159610, "DrawAutoMapVertWall__Fiii", SN_NOWARN)
set_name(0x801596B8, "DrawAutoMapHorzWall__Fiii", SN_NOWARN)
set_name(0x80159760, "DrawAutoMapVertDoor__Fii", SN_NOWARN)
set_name(0x801598D8, "DrawAutoMapHorzDoor__Fii", SN_NOWARN)
set_name(0x80159A58, "DrawAutoMapVertGrate__Fii", SN_NOWARN)
set_name(0x80159AEC, "DrawAutoMapHorzGrate__Fii", SN_NOWARN)
set_name(0x80159B80, "DrawAutoMapSquare__Fii", SN_NOWARN)
set_name(0x80159C98, "DrawAutoMapStairs__Fii", SN_NOWARN)
set_name(0x80159E40, "DrawAutomap__Fv", SN_NOWARN)
set_name(0x8015A19C, "PRIM_GetPrim__FPP7LINE_F2", SN_NOWARN)
|
""" Third party dependencies for this project. """
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
def zola_deps():
""" Fetches the dependencies for the zola project. """
if "zola-v0-14-1-x86-64-unknown-linux-gnu" not in native.existing_rules():
http_archive(
name = "zola-v0-14-1-x86-64-unknown-linux-gnu",
url = "https://github.com/getzola/zola/releases/download/v0.14.1/zola-v0.14.1-x86_64-unknown-linux-gnu.tar.gz",
build_file = "@rules_zola//third_party:zola-v0-14-1-x86-64-unknown-linux-gnu.BUILD",
sha256 = "4223f57d9b60ad7217c44a815fa975b2229f692b7ef3de4b7ce61f1634e8dc33",
)
if "zola-v0-14-1-x86_64-apple-darwin" not in native.existing_rules():
http_archive(
name = "zola-v0-14-1-x86_64-apple-darwin",
url = "https://github.com/getzola/zola/releases/download/v0.14.1/zola-v0.14.1-x86_64-apple-darwin.tar.gz",
build_file = "@rules_zola//third_party:zola-v0-14-1-x86_64-apple-darwin.BUILD",
sha256 = "754d5e1b4ca67a13c6cb4741dbff5b248075f4f4a0353d6673aa4f5afb7ec0bf",
)
if "zola-v0-14-1-x86_64-pc-windows-msvc" not in native.existing_rules():
http_archive(
name = "zola-v0-14-1-x86_64-pc-windows-msvc",
url = "https://github.com/getzola/zola/releases/download/v0.14.1/zola-v0.14.1-x86_64-pc-windows-msvc.zip",
build_file = "@rules_zola//third_party:zola-v0-14-1-x86_64-pc-windows-msvc.BUILD",
sha256 = "62bf50a6e2b606faf80cdf9112deca945fe89f67863fb06f793c27a26c968a91",
)
if "bazel_skylib" not in native.existing_rules():
http_archive(
name = "bazel_skylib",
sha256 = "c6966ec828da198c5d9adbaa94c05e3a1c7f21bd012a0b29ba8ddbccb2c93b0d",
urls = [
"https://github.com/bazelbuild/bazel-skylib/releases/download/1.1.1/bazel-skylib-1.1.1.tar.gz",
"https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.1.1/bazel-skylib-1.1.1.tar.gz",
],
)
|
# ===================== 路径配置 ============================
folder_path = "folder/path/"
tex_raw_path = folder_path + "raw.tex"
tex_out_path = folder_path + "out.tex"
# ================== 实验报告表头信息 ============================
stid = "173530xx"
major = "物理学"
grade = "17级"
name = "木一"
# ================== tex 导言区设置 ============================
# 推荐使用 StarHub 设计好的实验模板 (链接如下)
# https://github.com/StarHub-SPA/Experiment_Report_SPA_Template
preamble = '''
\\documentclass[no-math,zihao = -4]{ctexart}
\\usepackage{"../../Experiment_Report_SPA_Template/loeng's_taste/spaexptemp"}
'''
|
#Printing stars in 'W' shape!
'''
* * *
* * * *
** **
* *
'''
i=0
j=3
for row in range(4):
for col in range(7):
if(col==0 or col==6) or (col==4 and row==1) or (col==5 and row==2):
print('*',end='')
elif row==i and col==j:
print('*', end='')
i+=1
j-=1
else:
print(end=' ')
print()
|
def get():
return [
'const',
'var',
'import',
'require',
'using',
'load',
'from',
'as'
]
|
'''
Stepik001132ITclassPyсh02p01st08THEORY02_20200610.py
'''
a, b, c = 'x', 'y', 'z'
print('{} {} {}'.format(a, b, c))
a, b, c = "xyz"
print('{} {} {}'.format(a, b, c))
a, b, c = 1, 2, 3
print('{} {} {}'.format(a, b, c))
a, b, *c, d, e = 1, 2, 3, 4, 5, 6, 7
print('{} {} {} {} {}'.format(a, b, c, d, e))
print(*c,sep='-')
*a, b, c, d, e = 1, 2, 3, 4, 5, 6, 7
print('{} {} {} {} {}'.format(a, b, c, d, e))
print(*a,sep='-')
a, b, c, d, *e = 1, 2, 3, 4, 5, 6, 7
print('{} {} {} {} {}'.format(a, b, c, d, e))
print(*e,sep='*')
#
|
def inlookuptable(value: str, lookuptable: str):
with open(lookuptable, "r") as lookuptablestream:
for table in lookuptablestream:
if table.strip("\n") == value:
return True
return False
|
# Labels for Nodes and Relationships
BOT_LABEL = "Bot"
USER_LABEL = "User"
TWEET_LABEL = "Tweet"
WROTE_LABEL = "WROTE"
RETWEET_LABEL = "RETWEETED"
QUOTE_LABEL = "QUOTED"
REPLY_LABEL = "REPLIED"
FOLLOW_LABEL = "FOLLOWS"
QUERY = "match (b:Bot) - [r] - (t:Tweet) - [r2] - (t2:Tweet)" \
"call apoc.cypher.run('with `t` as t match (u:User) -[]-(t) return u, t limit 50', {t:t}) " \
"Yield value "\
"return b, value.u, t, r2, t2 " \
"limit 150"
|
def my_first_module_func():
print('you are using my first created module')
def console_log(message):
print(message)
|
def cuadrado1(num1):
return num1**2
cuadrado2 = lambda num1: num1 ** 2
print(cuadrado1(5))
print(cuadrado2(5))
|
MODE_5X11 = 0b00000011
class I2cConstants:
def __init__(self):
self.I2C_ADDR = 0x60
self.CMD_SET_MODE = 0x00
self.CMD_SET_BRIGHTNESS = 0x19
self.MODE_5X11 = 0b00000011
class IS31FL3730:
def __init__(self, smbus, font):
self.bus = smbus
self.font = font
self.i2cConstants = I2cConstants()
self._rotate = False
self.bus = self.bus.SMBus(1)
self.buffer = [0] * 11
self.offset = 0
self.error_count = 0
self.set_mode(self.i2cConstants.MODE_5X11)
def set_rotate(self, value):
self._rotate = value
def rotate5bits(self, x):
r = 0
if x & 16:
r = r | 1
if x & 8:
r = r | 2
if x & 4:
r = r | 4
if x & 2:
r = r | 8
if x & 1:
r = r | 16
return r
def update(self):
if self.offset + 11 <= len(self.buffer):
self.window = self.buffer[self.offset:self.offset + 11]
else:
self.window = self.buffer[self.offset:]
self.window += self.buffer[:11 - len(self.window)]
if self._rotate:
self.window.reverse()
for i in range(len(self.window)):
self.window[i] = self.rotate5bits(self.window[i])
self.window.append(0xff)
try:
self.bus.write_i2c_block_data(self.i2cConstants.I2C_ADDR, 0x01, self.window)
except IOError:
self.error_count += 1
if self.error_count == 10:
print("A high number of IO Errors have occurred, please check your soldering/connections.")
def set_mode(self, mode=MODE_5X11):
self.bus.write_i2c_block_data(self.i2cConstants.I2C_ADDR, self.i2cConstants.CMD_SET_MODE, [self.i2cConstants.MODE_5X11])
def get_brightness(self):
if hasattr(self, 'brightness'):
return self.brightness
return -1
def set_brightness(self, brightness):
self.brightness = brightness
self.bus.write_i2c_block_data(self.i2cConstants.I2C_ADDR, self.i2cConstants.CMD_SET_BRIGHTNESS, [self.brightness])
def set_col(self, x, value):
if len(self.buffer) <= x:
self.buffer += [0] * (x - len(self.buffer) + 1)
self.buffer[x] = value
def write_string(self, chars, x = 0):
for char in chars:
if ord(char) == 0x20 or ord(char) not in self.font:
self.set_col(x, 0)
x += 1
self.set_col(x, 0)
x += 1
self.set_col(x, 0)
x += 1
else:
font_char = self.font[ord(char)]
for i in range(0, len(font_char)):
self.set_col(x, font_char[i])
x += 1
self.set_col(x, 0)
x += 1 # space between chars
self.update()
# draw a graph across the screen either using
# the supplied min/max for scaling or auto
# scaling the output to the min/max values
# supplied
def graph(self, values, low=None, high=None):
values = [float(x) for x in values]
if low == None:
low = min(values)
if high == None:
high = max(values)
span = high - low
for col, value in enumerate(values):
value -= low
value /= span
value *= 5
if value > 5: value = 5
if value < 0: value = 0
self.set_col(col, [0,16,24,28,30,31][int(value)])
self.update()
def set_buffer(self, replacement):
self.buffer = replacement
def buffer_len(self):
return len(self.buffer)
def scroll(self, delta = 1):
self.offset += delta
self.offset %= len(self.buffer)
self.update()
def clear_buffer(self):
self.offset = 0
self.buffer = [0] * 11
def clear(self):
self.clear_buffer()
self.update()
def load_font(self, new_font):
self.font = new_font
def scroll_to(self, pos = 0):
self.offset = pos
self.offset %= len(self.buffer)
self.update()
def io_errors(self):
return self.error_count
def set_pixel(self, x,y,value):
if value:
self.buffer[x] |= (1 << y)
else:
self.buffer[x] &= ~(1 << y)
|
def sum_list(numbers):
total = 0
for i in numbers:
total += i
return total
print(sum_list([1, 2, -8]))
"""
Write a Python program to sum all the items in a list
"""
|
#Imagine you are building a compiler. Before running any code, the compiler must check that the parentheses in the program are balanced. Every opening bracket must have a corresponding closing bracket. We can approximate this using strings.
#Given a string containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid.
#An input string is valid if:
#- Open brackets are closed by the same type of brackets.
#- Open brackets are closed in the correct order.
#- Note that an empty string is also considered valid.
#Example:
#Input: "((()))"
#Output: True
#Input: "[()]{}"
#Output: True
#Input: "({[)]"
#Output: False
class Solution:
def closePara (self, s):
if( s == '('):
return (')', False)
elif (s == '{'):
return ('}', False)
elif (s == '['):
return (']', False)
else:
return (s, True)
def appendStack (self, c, paraStack):
paraStack.append(c)
def isValid(self, s):
# Fill this in.
paraStack=[]
lastPara=''
for ch in s:
if(lastPara == ''):
lastPara = ch
paraStack.append(ch)
continue
nextPara, isclosed = self.closePara(ch)
if isclosed:
#pop stack
if(len(paraStack) <= 0):
return False
expectPara,isclosed = self.closePara(paraStack[-1:][0])
if(expectPara != ch):
return False
else:
paraStack.pop()
else:
#put stack
paraStack.append(ch)
if(len(paraStack) != 0 ):
return False
else:
return True
if __name__ == "__main__":
# Test Programs
s = "()(){(())"
# should return False
print(Solution().isValid(s))
s = ""
# should return True
print(Solution().isValid(s))
s = "([{}])()"
# should return True
print(Solution().isValid(s))
s = "([{}])())"
# should return True
print(Solution().isValid(s))
s = "([{}])("
# should return True
print(Solution().isValid(s))
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.