content
stringlengths 7
1.05M
|
|---|
A = [[1, 2], [3, 4], [5, 6]]
B = max(A)
V = 1
|
class config_library:
def __init__(self, default):
self.path = default.path + "/system/library/"
self.ignore = ['__pycache__', '__init__.py']
def get(self):
return self
|
# Usando imágenes
# Por lo pronto primero hay que agregarlas desde Processing > Sketch > Añadir archivo
def setup():
frameRate(2);
smooth();
global img
global img2
size(400, 400);
# Make a new instance of a PImage by loading an image file
# Declaring a variable of type PImage
img = loadImage("vintage-dancers.png")
img2 = loadImage("vintage-dancers2.png")
def draw():
background(176,216,116);
# Draw the image to the screen
image(img, random(width-80), random(height-80), 110, 110);
image(img2, random(width-80), random(height-80), 110, 110);
|
"""
OptimalK module.
This module is used to determine the best number of clusters in functional
data.
"""
|
f = open("/home/vleite/Desktop/range.txt", "w")
f.write("x range:\n")
for x in range(0, 55296, 64):
f.write(str(x) + "-" + str(x + 64) + "\n")
f.write("y range:\n")
for x in range(0, 46080, 64):
f.write(str(x) + "-" + str(x + 64) + "\n")
f.write("z range:\n")
for x in range(0, 514, 64):
f.write(str(x) + "-" + str(x + 64) + "\n")
print("done!")
|
class Solution(object):
def runningSum(self, nums):
"""
:type nums: List[int]
:rtype: List[int]
"""
add_nums = 0
running_sum = []
for x in nums:
add_nums = add_nums + x
running_sum.append(add_nums)
return running_sum
|
pkgname = "libmodplug"
pkgver = "0.8.9.0"
pkgrel = 0
build_style = "gnu_configure"
configure_args = ["--enable-static"]
hostmakedepends = ["pkgconf"]
pkgdesc = "MOD playing library"
maintainer = "q66 <q66@chimera-linux.org>"
license = "custom:none"
url = "http://modplug-xmms.sourceforge.net"
source = f"$(SOURCEFORGE_SITE)/modplug-xmms/{pkgname}-{pkgver}.tar.gz"
sha256 = "457ca5a6c179656d66c01505c0d95fafaead4329b9dbaa0f997d00a3508ad9de"
@subpackage("libmodplug-devel")
def _devel(self):
return self.default_devel()
|
class Solution:
def lengthOfLongestSubstring(self, s):
"""
:type s: str
:rtype: int
"""
res = 0
maxRes = 0
strs = ''
for i in range(len(s)):
pos = strs.find(s[i])
if pos != -1:
if res > maxRes:
maxRes = res
strs = strs[pos+1:] + s[i]
res = len(strs)
else:
strs += s[i]
res += 1
return maxRes if maxRes > res else res
if __name__ == "__main__":
solution = Solution()
print(solution.lengthOfLongestSubstring('aasdciaclasj'))
|
# Copyright (c) 2008, Michael Lunnay <mlunnay@gmail.com.au>
#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
"""Custom exception heirachy for jsonrpc."""
class JSONRPCError(Exception):
def __init__(self, code, msg, data=None):
self.code = code
self.message = msg
self.data = data
def __str__(self):
out = "JSON-RPCError(%d:%s)" % (self.code, self.message)
if self.data:
out += ": %s" % str(self.data)
return out
def json_equivalent(self):
"""return a json encodable object that represents this Exception."""
obj = {'code': self.code, 'message': self.message}
if self.data != None:
obj['data'] = self.data
return obj
class ParseError(JSONRPCError):
def __init__(self, data=None):
JSONRPCError.__init__(self, -32700, "Parse error", data)
class InvalidRequestError(JSONRPCError):
def __init__(self, data=None):
JSONRPCError.__init__(self, -32600, "Invalid Request", data)
class MethodNotFoundError(JSONRPCError):
def __init__(self, data=None):
JSONRPCError.__init__(self, -32601, "Method not found", data)
class InvalidParametersError(JSONRPCError):
def __init__(self, data=None):
JSONRPCError.__init__(self, -32602, "Invalid params", data)
class InternalError(JSONRPCError):
def __init__(self, data=None):
JSONRPCError.__init__(self, -32603, "Internal error", data)
class ApplicationError(JSONRPCError):
def __init__(self, data=None):
JSONRPCError.__init__(self, -32000, "Application error", data)
class JSONRPCAssertionError(JSONRPCError):
def __init__(self, data=None):
JSONRPCError.__init__(self, -32001, "Assertion error", data)
class JSONRPCNotImplementedError(JSONRPCError):
def __init__(self, data=None):
JSONRPCError.__init__(self, -32002, "Not Implemented", data)
|
# O(1) constant time!
def print_one_item(items):
print(items[0])
# liniar O(n)
def print_every_item(items):
for item in items:
print(item)
# n = number of steps
# quadratic O(n^2)
def print_pairs(items):
for item_one in items:
for item_two in items:
print(item_one, item_two)
def do_a_bunch_of_stuff(items):
last_idx = len(items) - 1 # O(1)
middle_idx = len(items) / 2 # O(1)
idx = 0 # O(1)
for item in items:
print(item) # O(1)
for item in items:
for item in items:
print(item, item)
while idx < middle_idx: # O(n/2) = O(1/2 * n) = O(n)
print("s")
idx = idx + 1
# ADD em
# O(n) + O(n^2) + O(n) + O(4)
# == O(n^2) + O(n) + O(1)
# O(n^2) is the most significant one = total run time
# Big O = the worst thing that could happen
|
class Aranet4Exception(BaseException):
"""
Base exception for pyaranet4
"""
pass
class Aranet4NotFoundException(Aranet4Exception):
"""
Exception that occurs when no suitable Aranet4 device is available
"""
pass
class Aranet4BusyException(Aranet4Exception):
"""
Exception that occurs when one attempts to fetch history from the device
while history for another sensor is being read
"""
pass
class Aranet4UnpairedException(Aranet4Exception):
"""
Exception that occurs when the Aranet4 device is detected but unpaired, and
no data can be read from it.
"""
pass
|
# Time: O(n)
# Space: O(c), c is the max of nums
# counting sort, inplace solution
class Solution(object):
def sortEvenOdd(self, nums):
"""
:type nums: List[int]
:rtype: List[int]
"""
def partition(index, nums):
for i in xrange(len(nums)):
j = i
while nums[i] >= 0:
j = index(j)
nums[i], nums[j] = nums[j], ~nums[i] # processed
for i in xrange(len(nums)):
nums[i] = ~nums[i] # restore values
def inplace_counting_sort(nums, left, right, reverse=False): # Time: O(n)
if right-left+1 == 0:
return
count = [0]*(max(nums[i] for i in xrange(left, right+1))+1)
for i in xrange(left, right+1):
count[nums[i]] += 1
for i in xrange(1, len(count)):
count[i] += count[i-1]
for i in reversed(xrange(left, right+1)): # inplace but unstable sort
while nums[i] >= 0:
count[nums[i]] -= 1
j = left+count[nums[i]]
nums[i], nums[j] = nums[j], ~nums[i]
for i in xrange(left, right+1):
nums[i] = ~nums[i] # restore values
if reverse: # unstable
while left < right:
nums[left], nums[right] = nums[right], nums[left]
left += 1
right -= 1
partition(lambda i: i//2 if i%2 == 0 else (len(nums)+1)//2+i//2, nums)
inplace_counting_sort(nums, 0, (len(nums)+1)//2-1)
inplace_counting_sort(nums, (len(nums)+1)//2, len(nums)-1, True)
partition(lambda i: 2*i if i < (len(nums)+1)//2 else 1+2*(i-(len(nums)+1)//2), nums)
return nums
# Time: O(nlogn)
# Space: O(n)
# sort, inplace solution
class Solution2(object):
def sortEvenOdd(self, nums):
"""
:type nums: List[int]
:rtype: List[int]
"""
def partition(index, nums):
for i in xrange(len(nums)):
j = i
while nums[i] >= 0:
j = index(j)
nums[i], nums[j] = nums[j], ~nums[i] # processed
for i in xrange(len(nums)):
nums[i] = ~nums[i] # restore values
partition(lambda i: i//2 if i%2 == 0 else (len(nums)+1)//2+i//2, nums)
nums[:(len(nums)+1)//2], nums[(len(nums)+1)//2:] = sorted(nums[:(len(nums)+1)//2]), sorted(nums[(len(nums)+1)//2:], reverse=True)
partition(lambda i: 2*i if i < (len(nums)+1)//2 else 1+2*(i-(len(nums)+1)//2), nums)
return nums
# Time: O(nlogn)
# Space: O(n)
# sort
class Solution3(object):
def sortEvenOdd(self, nums):
"""
:type nums: List[int]
:rtype: List[int]
"""
nums[::2], nums[1::2] = sorted(nums[::2]), sorted(nums[1::2], reverse=True)
return nums
|
"""
link: https://leetcode-cn.com/problems/paint-house-ii
problem: 给 n*k 的数组,每项选一个数字,相邻选中的列数不能一致,求最小和,要求时间复杂O(nk)
solution: DP。dp状态很清晰,dp[i][j] 表示选到第 i 行时,选中第 j 项的当前最小和,显然有
dp[i][j] = min(min(dp[i-1][:j]), min(dp[i-1][j+1:])),区别只是填表的方式。
O(nkk)的思路很容易想到,每次遍历 dp[i-1] 的每一项找到最小值,每项花时间是O(k)。在这里做个优化,左右各扫一轮记录
left[:j], right[j:] 的最小值,即可优化到O(1),总时间即为 O(nk)。加滚动数组做压缩。
solution: 只记录 dp[i-1] 的最小值和第二小值即可,当与最小值相等时取第二小。
"""
class Solution:
def minCostII(self, costs: List[List[int]]) -> int:
if not len(costs) or not len(costs[0]):
return 0
n, k = len(costs), len(costs[0])
if len(costs[0]) == 1:
return sum([costs[i][0] for i in range(n)])
dp = [costs[0][i] for i in range(k)]
left, right = [_ for _ in range(k)], [_ for _ in range(k)]
for i in range(1, n):
for j in range(k):
left[j] = dp[j] if j == 0 else min(left[j - 1], dp[j])
for j in reversed(range(k)):
right[j] = dp[j] if j == k - 1 else min(right[j + 1], dp[j])
dp[0], dp[k - 1] = right[1] + costs[i][0], left[k - 2] + costs[i][k - 1]
for j in range(1, k - 1):
dp[j] = min(left[j - 1], right[j + 1]) + costs[i][j]
return min(dp)
# ---
class Solution:
def minCostII(self, costs: List[List[int]]) -> int:
if not len(costs) or not len(costs[0]):
return 0
n, k = len(costs), len(costs[0])
if len(costs[0]) == 1:
return sum([costs[i][0] for i in range(n)])
dp = [costs[0][i] for i in range(k)]
for i in range(1, n):
fm, sm = dp[0], float("inf")
for j in range(1, k):
if dp[j] <= fm:
sm = fm
fm = dp[j]
elif dp[j] < sm:
sm = dp[j]
for j in range(0, k):
dp[j] = (fm if dp[j] != fm else sm) + costs[i][j]
return min(dp)
|
# https://leetcode.com/problems/shortest-common-supersequence/
# Reference
# https://www.geeksforgeeks.org/print-shortest-common-supersequence/
# https://www.youtube.com/watch?v=823Grn4_dCQ&list=PL_z_8CaSLPWekqhdCPmFohncHwz8TY2Go&index=25&ab_channel=AdityaVerma
class Solution(object):
# Runtime: 368 ms, faster than 81.48% of Python online submissions for Shortest Common Supersequence .
# Memory Usage: 21.6 MB, less than 87.04% of Python online submissions for Shortest Common Supersequence .
def shortestCommonSupersequence(self, str1, str2):
"""
:type str1: str
:type str2: str
:rtype: str
"""
def longestCommonSubsequence (str1, str2):
dp= [[0]*(len(str2)+1) for i in range (len(str1)+1)]
for i in range (1,len(str1)+1):
for j in range (1, len(str2)+1):
if str1[i-1]==str2[j-1]:
dp[i][j] = 1+dp[i-1][j-1]
else:
dp[i][j] = max(dp[i-1][j], dp[i][j-1])
return printSCS (dp, str1, str2)
def printSCS(dp, str1, str2):
pstr1 = len(str1)
pstr2 = len(str2)
string = ""
while pstr1*pstr2 !=0:
if str1[pstr1-1] == str2[pstr2-1]:
string += str1[pstr1-1]
pstr1-=1
pstr2-=1
elif dp[pstr1][pstr2-1] > dp[pstr1-1][pstr2]:
string+= str2[pstr2-1]
pstr2-=1
else:
string +=str1[pstr1-1]
pstr1-=1
while pstr1:
string+=str1[pstr1-1]
pstr1-=1
while pstr2:
string+=str2[pstr2-1]
pstr2-=1
return string[::-1]
return longestCommonSubsequence(str1, str2)
print(Solution().shortestCommonSupersequence("abac", "cab"))
print(Solution().shortestCommonSupersequence("AGGTAB","GXTXAYB"))
|
# content of test_example.py (adapted from https://docs.pytest.org)
def inc(x):
"""Functionality that we want to test"""
return x + 1
def test_inc():
# This will give an error
# assert inc(3) == 5
# This will not
# (to see this: comment assertion line above,
# uncomment line below and re-run pytest)
assert inc(4) == 5
|
word = input()
times = int(input())
def repeat():
text = ""
for _ in range(times):
text += word
print(text)
repeat()
|
total = list([[], []])
while True:
for c in range(1, 8):
valor = int(input(f'Digite o {c} valor: '))
if valor % 2 == 0:
total[0].append(valor)
if valor % 2 != 0:
total[1].append(valor)
total[0].sort()
total[1].sort()
print(f'Os valores pares em ordem crescente são {total[0]}')
print(f'Os valores ímpares em ordem crescente são {total[1]}')
break
|
# Exercício Python 049
# Refaça o desafio 009, tabuada utilizando o FOR
n = int(input('Digite um número: '))
for c in range(1,11):
print('{:2} x {:2} = {:2}'.format(n,c,c*n))
|
class STLException(Exception):
pass
class STLParseException(Exception):
pass
class STLOfflineException(Exception):
pass
|
class TypeDeclaration:
def __init__(self, file_path):
self.file_path = file_path
self.types_declared = set()
def add_type_declared(self, new_type):
if type(new_type) == set:
self.types_declared = self.types_declared.union(new_type)
else:
self.types_declared.add(new_type)
def get_json_representation(self):
return {
"file_path" : self.file_path,
"type_declared" : list(self.types_declared)
}
|
'''
- Leetcode problem: 797
- Difficulty: Medium
- Brief problem description:
Given a directed, acyclic graph of N nodes. Find all possible paths from node 0 to node N-1, and return them in any
order.
The graph is given as follows: the nodes are 0, 1, ..., graph.length - 1. graph[i] is a list of all nodes j for which
the edge (i, j) exists.
Example:
Input: [[1,2], [3], [3], []]
Output: [[0,1,3],[0,2,3]]
Explanation: The graph looks like this:
0--->1
| |
v v
2--->3
There are two paths: 0 -> 1 -> 3 and 0 -> 2 -> 3.
Note:
The number of nodes in the graph will be in the range [2, 15].
You can print different paths in any order, but you should keep the order of nodes inside one path.
- Solution Summary:
- Used Resources:
--- Bo Zhou
'''
class Solution:
def allPathsSourceTarget(self, graph: List[List[int]]) -> List[List[int]]:
result = []
self.dfs([0], 0, graph, result)
return result
def dfs(self, route, n, graph, result):
if n == len(graph) - 1:
result.append(route[:])
return
for dest in graph[n]:
route.append(dest)
self.dfs(route, dest, graph, result)
route.pop(-1)
|
class BnBTreeNode(object):
"""
BnBTreeNode 是 BnBTree 的节点
Fields
------
left : BnBTreeNode, 左子节点,分支定界法里的左枝
right : BnBTreeNode, 右子节点,分支定界法里的右枝
x_idx : int, 分支定界法里新增条件的变量索引
x_c : str, 分支定界法里新增条件的比较运算符 "<=" 或 ">="
x_b : float, 分支定界法里新增条件的右端常数
res_x : numpy array, 分支定界法里这一步的松弛解
res_fun : float, 分支定界法里这一步的目标函数值
sub_flag: bool, 若节点为*整颗BnBTree*的根节点则为 False,否则 True
"""
def __init__(self):
super().__init__()
self.left = None
self.right = None
self.x_idx = None
self.x_c = None
self.x_b = None
self.res_x = None
self.res_fun = None
self.sub_flag = True
def __str__(self):
if self.sub_flag:
return f'x[{self.x_idx}] {self.x_c} {self.x_b}: {self.res_x} -> {self.res_fun}'
else:
return f'Root: {self.res_x} -> {self.res_fun}'
class BnBTree(object):
"""
BnBTree 是表示分枝定界法求整数规划问题过程的树
Fields
------
root: 树根节点
"""
def __init__(self):
super().__init__()
self.root = BnBTreeNode()
self.root.sub_flag = False
self.__str_tree = ""
def __str__(self):
if self.__str_tree == "":
def walk(node, indentation):
self.__str_tree += "\t|" * indentation + "-- "
# print("\t|" * indentation + "--", end=" ")
self.__str_tree += str(node) + "\n"
# print(node)
if node.left:
walk(node.left, indentation + 1)
if node.right:
walk(node.right, indentation + 1)
walk(self.root, 0)
return self.__str_tree
def _bnb_tree_test():
tree = BnBTree()
tree.root.left = BnBTreeNode()
tree.root.left.res_fun = "left"
tree.root.right = BnBTreeNode()
tree.root.right.res_fun = "right"
tree.root.right.left = BnBTreeNode()
tree.root.right.left.res_fun = "rl"
tree.root.right.right = BnBTreeNode()
tree.root.right.right.res_fun = "rr"
tree.root.right.left.left = BnBTreeNode()
tree.root.right.left.left.res_fun = "rll"
print(tree)
if __name__ == "__main__":
_bnb_tree_test()
|
#Dictionary adalah stuktur data yang bentuknya seperti kamus.
#Ada kata kunci kemudian ada nilaninya. Kata kunci harus unik,
#sedangkan nilai boleh diisi denga apa saja.
# Membuat Dictionary
ira_abri = {
"nama": "ira abri",
"umur": 19,
"hobi": ["makan", "jalan", "ngemoll"],
"menikah": False,
"sosmed": {
"facebook": "iraabri",
"twitter": "@irakode"
}
}
# Mengakses isi dictionary
print("Nama saya adalah %s" % ira_abri["nama"])
print("Twitter: %s" % ira_abri["sosmed"]["twitter"])
|
class WorkBot:
def __init__(self):
self.driver = webdriver.Chrome()
self.driver.get("https://app.daily.dev/")
self.WebDriverWait(self.driver).until(document_initialised)
el = self.driver.find_element_by_xpath("/html/body/div/main/div/article/a")
# names = [name.text for name in el if name != '']
for e in el:
print(el)
WorkBot()
class WorkBot:
def __init__(self, timeout=None):
options = Options()
options.page_load_strategy = 'normal'
self.driver = webdriver.Chrome(options=options)
self.driver.get('https://app.daily.dev/')
elements = WebDriverWait(self.driver).until(lambda d: d.find_element_by_tag_name("article"))
for e in elements:
print(e.text)
# WebDriverWait(self.driver).until(self.document_initialised)
# self.wait = WebDriverWait(self.driver, 10)
# self.driver.implicitly_wait(60)
# divElement = self.driver.find_element_by_css_selector("#cards_title__1SQYH")
# str = divElement.getText()
# self.System.out.println(str)
WorkBot()
|
# This code is written in Python
# This code prints the line number next to each line in the file
FileName = "file1.txt"
f = open(FileName,"r")
fileContent = f.read()
number_of_lines = 0
line_by_line = fileContent.split("\n")
number_of_lines = len(line_by_line)
print("The number of lines in the file are : ")
print(number_of_lines)
newContents = ""
lineIndex = 1
for line in line_by_line:
newContents = newContents + "Line #" +str(lineIndex) + ": " + line + "\n"
lineIndex=lineIndex+1
fNewFile = open("NumberedFile-" + FileName,"w")
fNewFile.write(newContents)
print("File has been created successfully")
|
class Event:
def __init__(self):
self._callee_list = set()
def __iadd__(self, fct):
return self._callee_list.add(fct)
def __isub__(self, fct):
return self._callee_list.remove(fct)
def __call__(self, sender, *event_args):
for callee in self._callee_list:
callee(sender, *event_args)
|
# https://www.geeksforgeeks.org/kmp-algorithm-for-pattern-searching/
def get_lps(pat):
n = len(pat)
lps = [0] * n # longest proper prefix which is also suffix
i = 1
l = 0
while i < n:
if pat[i] == pat[l]:
l += 1
lps[i] = l
i += 1
else:
if 0 < l:
l = lps[l-1]
else:
i += 1
return lps
def find(text, pat):
res = []
n = len(text)
m = len(pat)
i = 0
l = 0
lps = get_lps(pat)
while i < n:
if text[i] == pat[l]:
i += 1
l += 1
else:
if 0 < l:
l = lps[l-1]
else:
i += 1
if l == m:
res.append(i-m)
l = lps[l-1]
return res
if __name__ == '__main__':
text = 'THIS IS A TEST TEXT'
pat = 'TEST'
[10] == find(text, pat)
text = 'AABAACAADAABAABA'
pat = 'AABA'
[0, 9, 12] == find(text, pat)
assert [0, 1, 2, 3]== get_lps('AAAA')
assert [0, 1, 2, 0]== get_lps('AAAB')
assert [0, 1, 0, 1]== get_lps('AABA')
assert [0, 0, 1, 2]== get_lps('ABAB')
assert [0, 1, 0, 1, 2] == get_lps('AACAA')
|
class ParsingSuccess:
def __init__(self, string, rule_type, start_pos, end_pos, children):
self.string = string
self.rule_type = rule_type
self.start_pos = start_pos
self.end_pos = end_pos
self.children = children
@property
def match_string(self):
return self.string[self.start_pos:self.end_pos]
|
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
class Pinentry(AutotoolsPackage):
"""pinentry is a small collection of dialog programs that allow GnuPG to
read passphrases and PIN numbers in a secure manner.
There are versions for the common GTK and Qt toolkits as well as for
the text terminal (Curses).
"""
homepage = "https://gnupg.org/related_software/pinentry/index.html"
url = "https://gnupg.org/ftp/gcrypt/pinentry/pinentry-1.1.0.tar.bz2"
maintainers = ['alalazo']
version('1.1.1', sha256='cd12a064013ed18e2ee8475e669b9f58db1b225a0144debdb85a68cecddba57f')
version('1.1.0', sha256='68076686fa724a290ea49cdf0d1c0c1500907d1b759a3bcbfbec0293e8f56570')
depends_on('libgpg-error@1.16:')
depends_on('libassuan@2.1.0:')
def configure_args(self):
return [
'--enable-static',
'--enable-shared',
# Autotools automatically enables these if dependencies found
# TODO: add variants for these
'--disable-pinentry-curses',
'--disable-pinentry-emacs',
'--disable-pinentry-gtk2',
'--disable-pinentry-gnome3',
'--disable-pinentry-qt',
'--disable-pinentry-qt5',
'--disable-pinentry-tqt',
'--disable-pinentry-fltk',
# No dependencies, simplest installation
'--enable-pinentry-tty',
# Disable extra features
'--disable-fallback-curses',
'--disable-inside-emacs',
'--disable-libsecret',
# Required dependencies
'--with-gpg-error-prefix=' + self.spec['libgpg-error'].prefix,
'--with-libassuan-prefix=' + self.spec['libassuan'].prefix,
]
|
#Faça um programa que leia o dia, o Mês e o Ano de seu nascimento.
Dia = input("Que dia você nasceu = ")
Mes = input("De qual mês = ")
Ano = input("De qual ano = ")
print("Você nasceu no dia ",Dia, "de",Mes, "de", Ano, ". Correto?")
|
# encoding=utf-8
WECHATGROUP = [u'运维告警',]
SDPURL = 'http://192.168.0.111:8050'
SDPAPIKEY = '5C45F603-DF68-4CC1-BB66-E923670EC2BD'
OPMURL = 'http://192.168.0.96:8060'
OPMAPIKEY = '67b287274fb1be2b449f1653508b7669'
LISTENERHOST = 'localhost'
LISTENERPORT = 6601
TULINGKEY = '8edce3ce905a4c1dbb965e6b35c3834d'
|
def information(*args):
for arg in args:
print(arg)
information(1, 3, 6, 7, "Abelardo")
def users(**kwargs):
for k in kwargs.values():
print(k)
users(name="bob", age=19)
|
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Дано предложение. Определить порядковые номера
# первой пары одинаковых соседних символов.
# Если таких символов нет,
# то должно быть напечатано соответствующее сообщение.
if __name__ == '__main__':
line = input("Введите предложение ")
for ind in range(len(line) - 1):
if line[ind] == line[ind + 1]:
print(ind + 1, ind + 2)
break
else:
print('Таких нет')
|
def sqr(n):
if (n**.5)%1==0:
return True
return False
l=[]
for d in range(2,1001):
if sqr(d)==False:
y=1
while True:
x=1+d*y*y
if sqr(x)==True:
print(x**.5,"^2 -",d,"*",y,"^2 = 1")
l.append(int(x**.5))
l.append(d)
break
y+=1
print(l[l.index(max(l))+1])
|
def soma_numeros(primeiro, segundo):
return primeiro + segundo
print(soma_numeros(15, 15))
|
def dict_eq(d1, d2):
return (all(k in d2 and d1[k] == d2[k] for k in d1)
and all(k in d1 and d1[k] == d2[k] for k in d2))
assert dict_eq(dict(a=2, b=3), {'a': 2, 'b': 3})
assert dict_eq(dict({'a': 2, 'b': 3}, b=4), {'a': 2, 'b': 4})
assert dict_eq(dict([('a', 2), ('b', 3)]), {'a': 2, 'b': 3})
a = {'g': 5}
b = {'a': a, 'd': 9}
c = dict(b)
c['d'] = 3
c['a']['g'] = 2
assert dict_eq(a, {'g': 2})
assert dict_eq(b, {'a': a, 'd': 9})
a.clear()
assert len(a) == 0
a = {'a': 5, 'b': 6}
res = set()
for value in a.values():
res.add(value)
assert res == set([5,6])
count = 0
for (key, value) in a.items():
assert a[key] == value
count += 1
assert count == len(a)
res = set()
for key in a.keys():
res.add(key)
assert res == set(['a','b'])
|
DISCORD_WEBHOOK_URL = 'https://discord.com/api/webhooks/{webhook_id}/{webhook_token}'
DISCORD_WEBHOOK_RELAY_PARAMS = [
'webhook_id',
'webhook_token',
'content',
]
|
class Forbidden(Exception):
pass
class InternalServerError(Exception):
pass
|
# -*- coding: utf-8 -*-
"""
test_nsct
----------------------------------
Tests for `nsct` module.
"""
class TestNsct(object):
@classmethod
def set_up(self):
pass
@classmethod
def tear_down(self):
pass
|
print('calculate area of a circle')
def circle():
radius = input('enter radius')
radius = float(radius)
area = 3.14*radius*radius
print ('area is ')
print (area)
circle()
|
h = list(map(int, input().rstrip().split()))
word = input()
h = [h[ord(l) - ord("a")] for l in set(word)]
print(max(h) * len(word))
|
load("//:import_external.bzl", import_external = "safe_wix_scala_maven_import_external")
def dependencies():
import_external(
name = "com_fasterxml_jackson_module_jackson_module_paranamer",
artifact = "com.fasterxml.jackson.module:jackson-module-paranamer:2.9.6",
artifact_sha256 = "dfd66598c0094d9a7ef0b6e6bb3140031fc833f6cf2e415da27bc9357cdfe63b",
srcjar_sha256 = "375052d977a4647b49a8512a2e269f3296c455544f080a94bc8855dbfd24ad75",
deps = [
"@com_fasterxml_jackson_core_jackson_databind",
"@com_thoughtworks_paranamer_paranamer"
],
)
import_external(
name = "com_fasterxml_jackson_module_jackson_module_scala_2_12",
artifact = "com.fasterxml.jackson.module:jackson-module-scala_2.12:2.9.6",
artifact_sha256 = "c775854c1da6fc4602d5850b65513d18cb9d955b3c0f64551dd58ccb24a85aba",
srcjar_sha256 = "5446419113a48ceb4fa802cd785edfc06531ab32763d2a2f7906293d1e445957",
deps = [
"@com_fasterxml_jackson_core_jackson_annotations",
"@com_fasterxml_jackson_core_jackson_core",
"@com_fasterxml_jackson_core_jackson_databind",
"@com_fasterxml_jackson_module_jackson_module_paranamer",
"@org_scala_lang_scala_library",
"@org_scala_lang_scala_reflect"
],
)
|
"""Version and details for pcraft"""
__description__ = "Pcraft"
__url__ = "https://www.github.com/devoinc/pcraft"
__version__ = "0.1.4"
__author__ = "Sebastien Tricaud"
__author_email__ = "sebastien.tricaud@devo.com"
__license__ = "MIT"
__maintainer__ = __author__
__maintainer_email__ = __author_email__
|
#!/usr/bin/env python
def plot(parser, args):
"""
To do.
"""
pass
if __name__ == "__main__":
plot()
|
# 前台信息编码表
FrontMessageCode = {}
# 后台信息编码表
BackMessageCode = {}
# 编码、语言
FrontMessageCode['1'] = {"Help": "Username_Empty", "Zh": "用户不能为空"}
FrontMessageCode['2'] = {"Help": "Password_Empty", "Zh": "密码不能为空"}
FrontMessageCode['3'] = {"Help": "Username_NotEqual_Password", "Zh": "用户名和密码不匹配"}
FrontMessageCode['4'] = {"Help": "LogoutFailed", "Zh": "登出失败"}
FrontMessageCode['5'] = {"Help": "Captcha_Empty", "Zh": "验证码不能为空"}
FrontMessageCode['6'] = {"Help": "Captcha_Wrong", "Zh": "验证码错误"}
FrontMessageCode['7'] = {"Help": "User_Exists", "Zh": "该用户名已存在"}
for key in FrontMessageCode.keys():
BackMessageCode[FrontMessageCode[key]['Help']] = key
def getFrontMessage():
return FrontMessageCode
def getBackMessage():
return BackMessageCode
|
# A game is a sequence of scores (positive for the home team,
# negative for the visiting team).
# For example, in American football, the set of valid scores is
# {2,3,6,7,8,-2,-3,-6,-7,-8}.
# For rugby, the set of valid scores in {3,5,7,-3,-5,-7}
# A tie-less game is one in which the teams are never in a tie
# (except at the beginning, when no team has scored yet).
def number_of_tieless_games(scoring_events, n):
"""
Takes in an iterable, scoring_events, containing the possible scores in the
game. For example, for football, it would be {1,-1}.
For rugby union, it would be [3,5,7,-3,-5,-7].
Negative points represent points for the away team, positive points
represent points for the home team
Also takes in n, a number of scoring events.
Returns a list of length n+1 where the ith entry is the number of tieless
games with i scoring events, where each scoring event is a member of
scoring_events.
For example, number_of_tieless_games({1,2,-1,-2},3) returns [1,4,12],
because there is a unique game with 0 scoring events.
Any game with 1 scoring event is tieless, and there are 4 of them.
Of the 16 (4**2) games with 2 scoring events, all apart from
[2,-2], [-2,2], [-1,1] and [1,-1] are tieless, so there are 12 which are
tieless.
"""
dictionary_of_scores = {0:1}
list_to_return = [1]
# The keys of this dictionary represent possible scores.
# The values represent the number of ways this score can be reached with
# the game being tied at every point.
for i in range(n):
# At each stage, we have the non-zero scores with i scoring events in
# dictionary_of_scores. To find non-zero scores with i+1 scoring events
# consider each non-zero score, and each possibility for the next
# scoring event.
old_dictionary = dictionary_of_scores
dictionary_of_scores = {}
for score, number_of_ways in old_dictionary.items():
for scoring_event in scoring_events:
new_score = score + scoring_event
if new_score != 0:
dictionary_of_scores[new_score] =\
dictionary_of_scores.get(new_score, 0) + number_of_ways
list_to_return.append(sum(dictionary_of_scores.values()))
return list_to_return
|
class Solution:
def getRow(self, rowIndex: int) -> List[int]:
if rowIndex == 0:
return [1]
s = [1]
for i in range(1, rowIndex + 1):
s = [sum(x) for x in zip([0] + s, s + [0])]
return s
|
#!/usr/bin/env python
class AsciiFileReader:
def __init__(self, infile):
self.infile = infile
def readInt(self):
assert False
|
coordinates_E0E1E1 = ((123, 109),
(123, 111), (123, 112), (123, 114), (124, 109), (124, 110), (125, 108), (125, 109), (125, 114), (126, 108), (126, 109), (127, 69), (127, 79), (127, 99), (127, 101), (127, 108), (128, 72), (128, 73), (128, 74), (128, 75), (128, 76), (128, 77), (128, 79), (128, 93), (128, 98), (128, 101), (128, 107), (128, 108), (129, 70), (129, 75), (129, 79), (129, 93), (129, 97), (129, 99), (129, 101), (129, 107), (130, 71), (130, 73), (130, 74), (130, 75), (130, 76), (130, 77), (130, 79), (130, 94), (130, 98), (130, 99), (130, 101), (130, 106), (130, 107), (131, 71), (131, 73), (131, 74), (131, 75), (131, 76), (131, 77), (131, 78), (131, 80), (131, 95), (131, 97), (131, 98), (131, 99), (131, 100), (131, 101), (131, 102), (131, 106), (132, 70), (132, 72), (132, 73), (132, 74), (132, 75), (132, 76), (132, 77), (132, 78),
(132, 80), (132, 95), (132, 97), (132, 98), (132, 99), (132, 100), (132, 101), (132, 103), (132, 105), (133, 69), (133, 71), (133, 72), (133, 73), (133, 74), (133, 75), (133, 76), (133, 77), (133, 78), (133, 79), (133, 81), (133, 96), (133, 98), (133, 99), (133, 100), (133, 101), (133, 102), (133, 104), (134, 66), (134, 67), (134, 68), (134, 70), (134, 71), (134, 72), (134, 73), (134, 74), (134, 75), (134, 76), (134, 77), (134, 78), (134, 79), (134, 80), (134, 82), (134, 96), (134, 98), (134, 99), (134, 100), (134, 101), (134, 103), (135, 66), (135, 71), (135, 72), (135, 73), (135, 74), (135, 75), (135, 76), (135, 77), (135, 78), (135, 79), (135, 80), (135, 81), (135, 84), (135, 97), (135, 99), (135, 100), (135, 101), (135, 103), (136, 68), (136, 69), (136, 72), (136, 73), (136, 74), (136, 75),
(136, 76), (136, 77), (136, 78), (136, 79), (136, 80), (136, 81), (136, 82), (136, 85), (136, 86), (136, 96), (136, 98), (136, 99), (136, 100), (136, 102), (136, 110), (137, 71), (137, 73), (137, 74), (137, 75), (137, 76), (137, 77), (137, 78), (137, 79), (137, 80), (137, 81), (137, 82), (137, 83), (137, 84), (137, 88), (137, 89), (137, 90), (137, 91), (137, 92), (137, 93), (137, 94), (137, 95), (137, 96), (137, 97), (137, 98), (137, 99), (137, 100), (137, 102), (138, 72), (138, 74), (138, 75), (138, 76), (138, 77), (138, 78), (138, 79), (138, 80), (138, 81), (138, 82), (138, 83), (138, 84), (138, 85), (138, 86), (138, 87), (138, 96), (138, 97), (138, 98), (138, 99), (138, 100), (138, 102), (138, 111), (139, 72), (139, 74), (139, 75), (139, 76), (139, 77), (139, 78), (139, 79), (139, 80),
(139, 81), (139, 82), (139, 83), (139, 84), (139, 85), (139, 86), (139, 87), (139, 88), (139, 89), (139, 90), (139, 91), (139, 92), (139, 93), (139, 94), (139, 95), (139, 96), (139, 97), (139, 98), (139, 99), (139, 100), (139, 101), (139, 102), (139, 111), (139, 112), (140, 72), (140, 74), (140, 75), (140, 76), (140, 77), (140, 78), (140, 79), (140, 80), (140, 81), (140, 82), (140, 83), (140, 84), (140, 85), (140, 86), (140, 87), (140, 88), (140, 89), (140, 90), (140, 91), (140, 92), (140, 93), (140, 94), (140, 95), (140, 96), (140, 97), (140, 98), (140, 99), (140, 100), (140, 101), (140, 102), (140, 105), (140, 110), (140, 113), (141, 71), (141, 73), (141, 74), (141, 75), (141, 76), (141, 77), (141, 78), (141, 79), (141, 80), (141, 81), (141, 82), (141, 83), (141, 84), (141, 85), (141, 86),
(141, 87), (141, 88), (141, 89), (141, 90), (141, 91), (141, 92), (141, 93), (141, 94), (141, 95), (141, 96), (141, 97), (141, 98), (141, 99), (141, 100), (141, 101), (141, 102), (141, 103), (141, 108), (141, 111), (141, 112), (141, 114), (142, 68), (142, 69), (142, 72), (142, 73), (142, 79), (142, 80), (142, 81), (142, 82), (142, 83), (142, 84), (142, 85), (142, 86), (142, 87), (142, 88), (142, 89), (142, 90), (142, 91), (142, 92), (142, 93), (142, 94), (142, 95), (142, 96), (142, 97), (142, 98), (142, 99), (142, 100), (142, 101), (142, 102), (142, 103), (142, 104), (142, 105), (142, 107), (142, 110), (142, 111), (142, 112), (142, 113), (142, 116), (142, 145), (143, 66), (143, 74), (143, 75), (143, 76), (143, 77), (143, 78), (143, 82), (143, 83), (143, 84), (143, 85), (143, 86), (143, 87), (143, 88),
(143, 89), (143, 90), (143, 91), (143, 92), (143, 93), (143, 94), (143, 95), (143, 96), (143, 97), (143, 98), (143, 99), (143, 100), (143, 101), (143, 102), (143, 103), (143, 104), (143, 105), (143, 106), (143, 108), (143, 109), (143, 110), (143, 111), (143, 112), (143, 113), (143, 114), (143, 117), (143, 143), (143, 146), (144, 66), (144, 68), (144, 69), (144, 70), (144, 71), (144, 72), (144, 73), (144, 79), (144, 80), (144, 81), (144, 82), (144, 83), (144, 84), (144, 85), (144, 86), (144, 87), (144, 88), (144, 89), (144, 90), (144, 91), (144, 92), (144, 93), (144, 94), (144, 95), (144, 96), (144, 97), (144, 98), (144, 99), (144, 100), (144, 101), (144, 102), (144, 103), (144, 104), (144, 105), (144, 106), (144, 107), (144, 108), (144, 109), (144, 110), (144, 111), (144, 112), (144, 113), (144, 114), (144, 115),
(144, 116), (144, 119), (144, 120), (144, 121), (144, 122), (144, 130), (144, 132), (144, 144), (144, 147), (145, 67), (145, 68), (145, 83), (145, 84), (145, 85), (145, 86), (145, 87), (145, 88), (145, 89), (145, 90), (145, 91), (145, 92), (145, 93), (145, 94), (145, 95), (145, 96), (145, 97), (145, 98), (145, 99), (145, 100), (145, 101), (145, 102), (145, 103), (145, 104), (145, 105), (145, 106), (145, 107), (145, 108), (145, 109), (145, 110), (145, 111), (145, 112), (145, 113), (145, 114), (145, 115), (145, 116), (145, 117), (145, 124), (145, 125), (145, 126), (145, 127), (145, 128), (145, 129), (145, 133), (145, 144), (145, 146), (145, 148), (146, 82), (146, 84), (146, 85), (146, 86), (146, 87), (146, 88), (146, 89), (146, 90), (146, 91), (146, 92), (146, 93), (146, 94), (146, 95), (146, 96), (146, 97), (146, 98),
(146, 99), (146, 100), (146, 101), (146, 102), (146, 103), (146, 104), (146, 105), (146, 106), (146, 107), (146, 108), (146, 109), (146, 110), (146, 111), (146, 112), (146, 113), (146, 114), (146, 115), (146, 116), (146, 117), (146, 118), (146, 119), (146, 120), (146, 121), (146, 122), (146, 130), (146, 131), (146, 132), (146, 145), (146, 148), (147, 81), (147, 83), (147, 84), (147, 85), (147, 86), (147, 87), (147, 88), (147, 89), (147, 90), (147, 91), (147, 92), (147, 93), (147, 94), (147, 95), (147, 96), (147, 97), (147, 98), (147, 99), (147, 100), (147, 101), (147, 102), (147, 103), (147, 104), (147, 105), (147, 106), (147, 107), (147, 108), (147, 109), (147, 110), (147, 111), (147, 112), (147, 113), (147, 114), (147, 115), (147, 116), (147, 117), (147, 118), (147, 119), (147, 120), (147, 121), (147, 122), (147, 123), (147, 124),
(147, 125), (147, 126), (147, 127), (147, 128), (147, 129), (147, 130), (147, 131), (147, 132), (147, 133), (147, 135), (147, 146), (147, 148), (148, 80), (148, 82), (148, 83), (148, 84), (148, 85), (148, 86), (148, 87), (148, 88), (148, 89), (148, 90), (148, 91), (148, 92), (148, 93), (148, 94), (148, 95), (148, 96), (148, 97), (148, 98), (148, 99), (148, 100), (148, 101), (148, 102), (148, 103), (148, 104), (148, 105), (148, 106), (148, 107), (148, 108), (148, 109), (148, 110), (148, 111), (148, 112), (148, 113), (148, 114), (148, 115), (148, 116), (148, 117), (148, 118), (148, 119), (148, 120), (148, 121), (148, 122), (148, 123), (148, 124), (148, 125), (148, 126), (148, 127), (148, 128), (148, 129), (148, 130), (148, 131), (148, 132), (148, 133), (148, 134), (148, 136), (148, 146), (148, 147), (149, 79), (149, 81), (149, 82),
(149, 83), (149, 84), (149, 85), (149, 86), (149, 92), (149, 93), (149, 94), (149, 95), (149, 96), (149, 97), (149, 98), (149, 99), (149, 100), (149, 101), (149, 102), (149, 103), (149, 104), (149, 105), (149, 106), (149, 107), (149, 108), (149, 109), (149, 110), (149, 111), (149, 112), (149, 113), (149, 116), (149, 117), (149, 118), (149, 119), (149, 120), (149, 121), (149, 122), (149, 123), (149, 124), (149, 125), (149, 126), (149, 127), (149, 128), (149, 129), (149, 130), (149, 131), (149, 132), (149, 133), (149, 134), (149, 136), (149, 146), (150, 78), (150, 80), (150, 81), (150, 82), (150, 83), (150, 84), (150, 87), (150, 88), (150, 89), (150, 90), (150, 91), (150, 94), (150, 95), (150, 96), (150, 97), (150, 98), (150, 99), (150, 100), (150, 101), (150, 102), (150, 103), (150, 104), (150, 105), (150, 106), (150, 107),
(150, 108), (150, 109), (150, 110), (150, 111), (150, 114), (150, 117), (150, 118), (150, 119), (150, 120), (150, 121), (150, 122), (150, 123), (150, 124), (150, 125), (150, 126), (150, 127), (150, 128), (150, 129), (150, 130), (150, 131), (150, 132), (150, 133), (150, 134), (150, 136), (150, 146), (151, 79), (151, 80), (151, 81), (151, 82), (151, 83), (151, 92), (151, 93), (151, 96), (151, 97), (151, 98), (151, 99), (151, 100), (151, 101), (151, 102), (151, 103), (151, 104), (151, 105), (151, 106), (151, 107), (151, 108), (151, 109), (151, 110), (151, 111), (151, 113), (151, 116), (151, 118), (151, 119), (151, 120), (151, 121), (151, 122), (151, 123), (151, 124), (151, 125), (151, 126), (151, 127), (151, 128), (151, 129), (151, 130), (151, 131), (151, 132), (151, 133), (151, 134), (151, 136), (152, 72), (152, 73), (152, 74), (152, 75),
(152, 78), (152, 79), (152, 80), (152, 81), (152, 82), (152, 84), (152, 94), (152, 97), (152, 98), (152, 99), (152, 100), (152, 101), (152, 102), (152, 103), (152, 104), (152, 105), (152, 106), (152, 107), (152, 108), (152, 109), (152, 111), (152, 117), (152, 127), (152, 128), (152, 129), (152, 130), (152, 131), (152, 132), (152, 133), (152, 134), (152, 136), (153, 70), (153, 76), (153, 77), (153, 78), (153, 79), (153, 80), (153, 83), (153, 96), (153, 98), (153, 99), (153, 100), (153, 101), (153, 102), (153, 103), (153, 104), (153, 105), (153, 106), (153, 107), (153, 108), (153, 109), (153, 111), (153, 118), (153, 120), (153, 121), (153, 122), (153, 123), (153, 124), (153, 125), (153, 126), (153, 130), (153, 131), (153, 132), (153, 133), (153, 134), (153, 136), (154, 70), (154, 73), (154, 74), (154, 75), (154, 76), (154, 77),
(154, 82), (154, 97), (154, 98), (154, 99), (154, 100), (154, 101), (154, 102), (154, 103), (154, 104), (154, 105), (154, 106), (154, 107), (154, 108), (154, 110), (154, 128), (154, 131), (154, 132), (154, 133), (154, 134), (154, 136), (155, 72), (155, 74), (155, 75), (155, 78), (155, 79), (155, 97), (155, 99), (155, 100), (155, 101), (155, 102), (155, 103), (155, 104), (155, 105), (155, 106), (155, 107), (155, 108), (155, 110), (155, 130), (155, 132), (155, 133), (155, 134), (155, 136), (155, 143), (156, 73), (156, 98), (156, 100), (156, 101), (156, 102), (156, 103), (156, 104), (156, 105), (156, 106), (156, 107), (156, 109), (156, 131), (156, 133), (156, 134), (156, 135), (156, 137), (156, 143), (156, 144), (157, 73), (157, 75), (157, 98), (157, 100), (157, 101), (157, 102), (157, 103), (157, 104), (157, 105), (157, 106), (157, 107),
(157, 109), (157, 131), (157, 133), (157, 134), (157, 135), (157, 136), (157, 139), (157, 143), (157, 144), (158, 73), (158, 74), (158, 98), (158, 100), (158, 101), (158, 102), (158, 103), (158, 104), (158, 105), (158, 106), (158, 107), (158, 109), (158, 131), (158, 133), (158, 134), (158, 135), (158, 136), (158, 137), (158, 139), (158, 143), (159, 98), (159, 100), (159, 101), (159, 102), (159, 103), (159, 104), (159, 105), (159, 106), (159, 107), (159, 109), (159, 131), (159, 133), (159, 134), (159, 135), (159, 136), (159, 137), (159, 138), (159, 142), (159, 143), (159, 144), (159, 146), (160, 99), (160, 101), (160, 102), (160, 103), (160, 104), (160, 105), (160, 106), (160, 108), (160, 131), (160, 133), (160, 134), (160, 135), (160, 136), (160, 137), (160, 138), (160, 139), (160, 143), (160, 145), (161, 99), (161, 101), (161, 102), (161, 103),
(161, 104), (161, 105), (161, 107), (161, 130), (161, 138), (161, 139), (161, 140), (161, 141), (161, 142), (161, 144), (162, 90), (162, 91), (162, 98), (162, 100), (162, 101), (162, 102), (162, 103), (162, 104), (162, 106), (162, 132), (162, 133), (162, 134), (162, 135), (162, 136), (162, 139), (162, 140), (162, 141), (162, 142), (162, 144), (163, 89), (163, 97), (163, 98), (163, 99), (163, 100), (163, 101), (163, 102), (163, 103), (163, 104), (163, 106), (163, 127), (163, 138), (163, 140), (163, 141), (163, 142), (163, 144), (164, 88), (164, 91), (164, 94), (164, 95), (164, 96), (164, 98), (164, 99), (164, 100), (164, 101), (164, 102), (164, 103), (164, 105), (164, 122), (164, 126), (164, 129), (164, 139), (164, 141), (164, 142), (164, 144), (165, 87), (165, 89), (165, 90), (165, 94), (165, 97), (165, 98), (165, 99), (165, 100),
(165, 101), (165, 102), (165, 103), (165, 104), (165, 105), (165, 106), (165, 122), (165, 124), (165, 125), (165, 127), (165, 129), (165, 140), (165, 142), (165, 144), (166, 86), (166, 87), (166, 96), (166, 98), (166, 99), (166, 100), (166, 101), (166, 102), (166, 103), (166, 104), (166, 106), (166, 123), (166, 126), (166, 128), (166, 140), (166, 142), (166, 143), (166, 144), (166, 145), (166, 146), (166, 148), (167, 79), (167, 81), (167, 82), (167, 83), (167, 84), (167, 96), (167, 98), (167, 99), (167, 101), (167, 102), (167, 103), (167, 104), (167, 105), (167, 107), (167, 124), (167, 127), (167, 141), (167, 143), (167, 144), (167, 149), (168, 80), (168, 83), (168, 95), (168, 100), (168, 104), (168, 105), (168, 106), (168, 108), (168, 124), (168, 125), (168, 127), (168, 141), (168, 143), (168, 144), (168, 145), (168, 146), (168, 147),
(168, 149), (169, 81), (169, 95), (169, 98), (169, 101), (169, 102), (169, 105), (169, 106), (169, 107), (169, 109), (169, 125), (169, 127), (169, 142), (169, 144), (169, 145), (169, 146), (169, 147), (169, 148), (169, 150), (170, 94), (170, 96), (170, 104), (170, 106), (170, 107), (170, 108), (170, 110), (170, 125), (170, 126), (170, 142), (170, 144), (170, 145), (170, 146), (170, 152), (171, 93), (171, 95), (171, 104), (171, 105), (171, 111), (171, 125), (171, 126), (171, 142), (171, 144), (171, 145), (171, 146), (171, 148), (171, 152), (172, 93), (172, 95), (172, 105), (172, 107), (172, 108), (172, 110), (172, 112), (172, 125), (172, 126), (172, 142), (172, 144), (172, 146), (172, 150), (172, 152), (173, 93), (173, 94), (173, 105), (173, 110), (173, 112), (173, 126), (173, 141), (173, 143), (173, 144), (173, 146), (173, 151), (174, 110),
(174, 112), (174, 124), (174, 126), (174, 141), (174, 143), (174, 144), (174, 146), (175, 104), (175, 111), (175, 124), (175, 126), (175, 140), (175, 142), (175, 143), (175, 144), (175, 146), (176, 104), (176, 111), (176, 113), (176, 124), (176, 126), (176, 139), (176, 141), (176, 142), (176, 146), (177, 111), (177, 113), (177, 124), (177, 126), (177, 138), (177, 140), (177, 141), (177, 142), (177, 143), (177, 145), (178, 111), (178, 113), (178, 125), (178, 137), (178, 139), (178, 140), (178, 142), (179, 112), (179, 113), (179, 125), (179, 136), (179, 140), (179, 142), (180, 113), (180, 125), (180, 136), (180, 138), (180, 139), (180, 142), (181, 124), (181, 125), (181, 141), (181, 142), (182, 124), (182, 125), (182, 141), (183, 124), (183, 125), (183, 141), (184, 125), (184, 141), (185, 125), (185, 141), )
coordinates_E1E1E1 = ((61, 138),
(62, 108), (62, 128), (62, 129), (62, 138), (63, 107), (63, 108), (63, 128), (63, 130), (63, 138), (63, 139), (64, 107), (64, 108), (64, 128), (64, 130), (64, 138), (64, 139), (64, 151), (65, 107), (65, 108), (65, 129), (65, 130), (65, 138), (65, 151), (66, 99), (66, 107), (66, 108), (66, 129), (66, 130), (66, 139), (66, 140), (66, 151), (67, 89), (67, 91), (67, 99), (67, 101), (67, 102), (67, 103), (67, 104), (67, 105), (67, 107), (67, 116), (67, 117), (67, 118), (67, 120), (67, 130), (67, 139), (67, 141), (67, 150), (68, 89), (68, 92), (68, 100), (68, 107), (68, 114), (68, 120), (68, 130), (68, 139), (68, 141), (68, 150), (69, 93), (69, 100), (69, 102), (69, 103), (69, 104), (69, 105), (69, 106), (69, 108), (69, 113), (69, 121), (69, 129), (69, 130), (69, 139), (69, 142),
(70, 95), (70, 99), (70, 100), (70, 101), (70, 102), (70, 103), (70, 104), (70, 105), (70, 106), (70, 107), (70, 108), (70, 109), (70, 110), (70, 111), (70, 116), (70, 117), (70, 118), (70, 120), (70, 130), (70, 139), (70, 142), (70, 149), (71, 96), (71, 97), (71, 98), (71, 100), (71, 101), (71, 102), (71, 103), (71, 104), (71, 105), (71, 106), (71, 107), (71, 108), (71, 114), (71, 128), (71, 130), (71, 140), (71, 142), (71, 149), (71, 150), (72, 100), (72, 101), (72, 102), (72, 103), (72, 104), (72, 105), (72, 106), (72, 107), (72, 108), (72, 109), (72, 110), (72, 111), (72, 127), (72, 130), (72, 140), (72, 142), (72, 149), (72, 150), (73, 99), (73, 101), (73, 102), (73, 103), (73, 104), (73, 105), (73, 106), (73, 107), (73, 108), (73, 109), (73, 110), (73, 112), (73, 128),
(73, 130), (73, 140), (73, 143), (73, 148), (73, 151), (74, 99), (74, 101), (74, 102), (74, 103), (74, 104), (74, 105), (74, 106), (74, 107), (74, 108), (74, 109), (74, 111), (74, 128), (74, 130), (74, 140), (74, 142), (74, 144), (74, 145), (74, 146), (74, 149), (74, 151), (75, 100), (75, 102), (75, 103), (75, 104), (75, 105), (75, 106), (75, 107), (75, 108), (75, 109), (75, 110), (75, 111), (75, 128), (75, 130), (75, 140), (75, 142), (75, 143), (75, 148), (75, 149), (75, 151), (76, 101), (76, 103), (76, 104), (76, 105), (76, 106), (76, 107), (76, 108), (76, 110), (76, 128), (76, 130), (76, 140), (76, 142), (76, 143), (76, 144), (76, 145), (76, 146), (76, 147), (76, 148), (76, 149), (76, 150), (76, 152), (77, 101), (77, 103), (77, 104), (77, 105), (77, 106), (77, 107), (77, 108),
(77, 110), (77, 128), (77, 130), (77, 140), (77, 142), (77, 143), (77, 144), (77, 145), (77, 152), (78, 102), (78, 104), (78, 105), (78, 106), (78, 107), (78, 108), (78, 110), (78, 127), (78, 129), (78, 131), (78, 139), (78, 141), (78, 142), (78, 143), (78, 144), (78, 145), (78, 147), (78, 148), (78, 149), (78, 150), (78, 152), (79, 102), (79, 104), (79, 105), (79, 106), (79, 107), (79, 108), (79, 110), (79, 126), (79, 133), (79, 139), (79, 141), (79, 142), (79, 143), (79, 145), (80, 102), (80, 104), (80, 105), (80, 106), (80, 107), (80, 108), (80, 110), (80, 129), (80, 130), (80, 131), (80, 134), (80, 138), (80, 140), (80, 141), (80, 142), (80, 143), (80, 145), (81, 102), (81, 104), (81, 105), (81, 106), (81, 107), (81, 108), (81, 110), (81, 125), (81, 126), (81, 127), (81, 132),
(81, 135), (81, 136), (81, 139), (81, 140), (81, 141), (81, 142), (81, 143), (81, 145), (82, 102), (82, 104), (82, 105), (82, 106), (82, 107), (82, 108), (82, 110), (82, 134), (82, 138), (82, 139), (82, 140), (82, 141), (82, 142), (82, 143), (82, 145), (83, 102), (83, 104), (83, 105), (83, 106), (83, 107), (83, 108), (83, 110), (83, 134), (83, 136), (83, 137), (83, 138), (83, 139), (83, 140), (83, 141), (83, 142), (83, 143), (83, 145), (84, 76), (84, 102), (84, 104), (84, 105), (84, 106), (84, 107), (84, 108), (84, 110), (84, 134), (84, 136), (84, 137), (84, 138), (84, 139), (84, 140), (84, 141), (84, 142), (84, 143), (84, 144), (84, 146), (85, 74), (85, 77), (85, 102), (85, 104), (85, 105), (85, 106), (85, 107), (85, 108), (85, 110), (85, 134), (85, 136), (85, 137), (85, 138),
(85, 139), (85, 143), (85, 144), (85, 147), (86, 73), (86, 76), (86, 78), (86, 101), (86, 103), (86, 104), (86, 105), (86, 106), (86, 107), (86, 108), (86, 110), (86, 134), (86, 136), (86, 137), (86, 138), (86, 141), (86, 142), (86, 143), (86, 144), (86, 145), (86, 149), (87, 72), (87, 75), (87, 76), (87, 77), (87, 79), (87, 100), (87, 102), (87, 103), (87, 104), (87, 105), (87, 106), (87, 107), (87, 108), (87, 110), (87, 134), (87, 136), (87, 137), (87, 139), (87, 143), (87, 145), (88, 72), (88, 74), (88, 75), (88, 76), (88, 77), (88, 78), (88, 98), (88, 101), (88, 102), (88, 103), (88, 104), (88, 105), (88, 106), (88, 107), (88, 108), (88, 109), (88, 111), (88, 133), (88, 135), (88, 136), (88, 138), (88, 144), (89, 72), (89, 75), (89, 76), (89, 77), (89, 78),
(89, 79), (89, 82), (89, 96), (89, 100), (89, 101), (89, 102), (89, 103), (89, 104), (89, 105), (89, 106), (89, 107), (89, 108), (89, 109), (89, 111), (89, 131), (89, 134), (89, 135), (89, 136), (89, 138), (89, 144), (90, 73), (90, 77), (90, 78), (90, 79), (90, 80), (90, 81), (90, 84), (90, 94), (90, 98), (90, 99), (90, 100), (90, 101), (90, 102), (90, 103), (90, 104), (90, 105), (90, 106), (90, 107), (90, 108), (90, 109), (90, 110), (90, 111), (90, 112), (90, 116), (90, 117), (90, 129), (90, 130), (90, 133), (90, 134), (90, 135), (90, 137), (90, 144), (91, 75), (91, 79), (91, 80), (91, 81), (91, 82), (91, 86), (91, 87), (91, 88), (91, 90), (91, 91), (91, 92), (91, 96), (91, 97), (91, 98), (91, 99), (91, 100), (91, 101), (91, 102), (91, 103), (91, 104),
(91, 105), (91, 106), (91, 107), (91, 108), (91, 109), (91, 110), (91, 111), (91, 114), (91, 115), (91, 118), (91, 119), (91, 120), (91, 121), (91, 122), (91, 123), (91, 124), (91, 125), (91, 126), (91, 127), (91, 131), (91, 132), (91, 133), (91, 134), (91, 135), (91, 137), (91, 144), (91, 145), (92, 77), (92, 81), (92, 82), (92, 83), (92, 84), (92, 85), (92, 89), (92, 93), (92, 94), (92, 95), (92, 96), (92, 97), (92, 98), (92, 99), (92, 100), (92, 101), (92, 102), (92, 103), (92, 104), (92, 105), (92, 106), (92, 107), (92, 108), (92, 109), (92, 110), (92, 111), (92, 112), (92, 113), (92, 116), (92, 117), (92, 128), (92, 129), (92, 130), (92, 131), (92, 132), (92, 133), (92, 134), (92, 136), (92, 145), (93, 79), (93, 83), (93, 84), (93, 85), (93, 86), (93, 87),
(93, 88), (93, 90), (93, 91), (93, 92), (93, 93), (93, 94), (93, 95), (93, 96), (93, 97), (93, 98), (93, 99), (93, 100), (93, 101), (93, 102), (93, 103), (93, 104), (93, 105), (93, 106), (93, 107), (93, 108), (93, 109), (93, 110), (93, 111), (93, 112), (93, 113), (93, 114), (93, 115), (93, 116), (93, 117), (93, 118), (93, 119), (93, 120), (93, 121), (93, 122), (93, 123), (93, 124), (93, 125), (93, 126), (93, 127), (93, 128), (93, 129), (93, 130), (93, 131), (93, 132), (93, 133), (93, 134), (93, 136), (94, 81), (94, 84), (94, 85), (94, 86), (94, 87), (94, 88), (94, 89), (94, 90), (94, 91), (94, 92), (94, 93), (94, 94), (94, 95), (94, 96), (94, 97), (94, 98), (94, 99), (94, 100), (94, 101), (94, 102), (94, 103), (94, 104), (94, 105), (94, 106), (94, 107),
(94, 108), (94, 109), (94, 110), (94, 111), (94, 112), (94, 113), (94, 114), (94, 115), (94, 116), (94, 117), (94, 118), (94, 119), (94, 120), (94, 121), (94, 122), (94, 123), (94, 124), (94, 125), (94, 126), (94, 127), (94, 128), (94, 129), (94, 130), (94, 131), (94, 132), (94, 133), (94, 134), (94, 136), (95, 83), (95, 85), (95, 86), (95, 87), (95, 88), (95, 89), (95, 90), (95, 91), (95, 92), (95, 93), (95, 94), (95, 95), (95, 96), (95, 97), (95, 98), (95, 99), (95, 100), (95, 101), (95, 102), (95, 103), (95, 104), (95, 105), (95, 106), (95, 107), (95, 108), (95, 109), (95, 110), (95, 111), (95, 112), (95, 113), (95, 114), (95, 115), (95, 116), (95, 117), (95, 118), (95, 119), (95, 120), (95, 121), (95, 122), (95, 123), (95, 124), (95, 125), (95, 126), (95, 127),
(95, 128), (95, 129), (95, 130), (95, 131), (95, 132), (95, 133), (95, 136), (96, 84), (96, 86), (96, 87), (96, 88), (96, 89), (96, 90), (96, 91), (96, 92), (96, 93), (96, 94), (96, 95), (96, 96), (96, 97), (96, 98), (96, 99), (96, 100), (96, 101), (96, 102), (96, 103), (96, 104), (96, 105), (96, 106), (96, 107), (96, 108), (96, 109), (96, 110), (96, 111), (96, 112), (96, 113), (96, 114), (96, 115), (96, 116), (96, 117), (96, 118), (96, 119), (96, 120), (96, 121), (96, 122), (96, 123), (96, 124), (96, 125), (96, 132), (96, 134), (96, 136), (96, 148), (97, 85), (97, 87), (97, 88), (97, 89), (97, 90), (97, 91), (97, 92), (97, 93), (97, 94), (97, 95), (97, 96), (97, 97), (97, 98), (97, 99), (97, 100), (97, 101), (97, 102), (97, 103), (97, 104), (97, 105),
(97, 106), (97, 107), (97, 108), (97, 109), (97, 110), (97, 111), (97, 112), (97, 113), (97, 114), (97, 115), (97, 116), (97, 117), (97, 118), (97, 119), (97, 120), (97, 126), (97, 127), (97, 128), (97, 129), (97, 130), (97, 131), (97, 136), (97, 148), (98, 86), (98, 88), (98, 89), (98, 90), (98, 91), (98, 92), (98, 93), (98, 94), (98, 95), (98, 96), (98, 97), (98, 98), (98, 99), (98, 100), (98, 101), (98, 102), (98, 103), (98, 104), (98, 105), (98, 106), (98, 107), (98, 108), (98, 109), (98, 110), (98, 111), (98, 112), (98, 113), (98, 114), (98, 115), (98, 116), (98, 117), (98, 121), (98, 122), (98, 123), (98, 124), (98, 132), (98, 147), (98, 149), (99, 86), (99, 88), (99, 89), (99, 90), (99, 91), (99, 92), (99, 93), (99, 94), (99, 95), (99, 96), (99, 97),
(99, 98), (99, 99), (99, 100), (99, 101), (99, 102), (99, 103), (99, 104), (99, 105), (99, 106), (99, 107), (99, 108), (99, 109), (99, 110), (99, 111), (99, 112), (99, 113), (99, 114), (99, 115), (99, 118), (99, 119), (99, 120), (99, 146), (99, 148), (100, 86), (100, 88), (100, 89), (100, 90), (100, 91), (100, 92), (100, 93), (100, 94), (100, 95), (100, 96), (100, 97), (100, 98), (100, 99), (100, 100), (100, 101), (100, 102), (100, 103), (100, 104), (100, 105), (100, 106), (100, 107), (100, 108), (100, 109), (100, 110), (100, 111), (100, 112), (100, 113), (100, 117), (100, 145), (100, 148), (101, 85), (101, 87), (101, 88), (101, 89), (101, 90), (101, 91), (101, 92), (101, 93), (101, 94), (101, 95), (101, 96), (101, 97), (101, 98), (101, 99), (101, 100), (101, 101), (101, 102), (101, 103), (101, 104),
(101, 105), (101, 106), (101, 110), (101, 111), (101, 112), (101, 115), (101, 144), (101, 147), (102, 86), (102, 87), (102, 88), (102, 89), (102, 90), (102, 91), (102, 92), (102, 93), (102, 94), (102, 95), (102, 96), (102, 97), (102, 98), (102, 99), (102, 100), (102, 101), (102, 102), (102, 105), (102, 107), (102, 108), (102, 109), (102, 111), (102, 114), (102, 144), (102, 146), (103, 81), (103, 82), (103, 85), (103, 86), (103, 87), (103, 88), (103, 89), (103, 90), (103, 91), (103, 92), (103, 93), (103, 94), (103, 95), (103, 96), (103, 97), (103, 98), (103, 99), (103, 100), (103, 101), (103, 102), (103, 104), (103, 110), (103, 112), (103, 144), (103, 145), (104, 79), (104, 80), (104, 83), (104, 84), (104, 85), (104, 86), (104, 87), (104, 88), (104, 89), (104, 90), (104, 91), (104, 92), (104, 93), (104, 94),
(104, 95), (104, 96), (104, 97), (104, 98), (104, 99), (104, 100), (104, 102), (104, 105), (104, 111), (105, 68), (105, 69), (105, 70), (105, 71), (105, 72), (105, 73), (105, 74), (105, 75), (105, 76), (105, 77), (105, 78), (105, 81), (105, 82), (105, 83), (105, 84), (105, 85), (105, 86), (105, 87), (105, 88), (105, 89), (105, 90), (105, 91), (105, 92), (105, 93), (105, 94), (105, 95), (105, 96), (105, 97), (105, 98), (105, 99), (105, 100), (105, 102), (106, 66), (106, 75), (106, 79), (106, 80), (106, 81), (106, 82), (106, 83), (106, 84), (106, 85), (106, 86), (106, 87), (106, 88), (106, 89), (106, 90), (106, 91), (106, 92), (106, 93), (106, 94), (106, 95), (106, 96), (106, 97), (106, 98), (106, 99), (106, 100), (106, 102), (107, 66), (107, 68), (107, 69), (107, 70), (107, 71), (107, 72),
(107, 73), (107, 74), (107, 75), (107, 76), (107, 77), (107, 78), (107, 79), (107, 80), (107, 81), (107, 82), (107, 83), (107, 84), (107, 85), (107, 86), (107, 87), (107, 88), (107, 89), (107, 90), (107, 91), (107, 92), (107, 97), (107, 98), (107, 99), (107, 100), (107, 102), (108, 67), (108, 69), (108, 70), (108, 71), (108, 72), (108, 73), (108, 74), (108, 75), (108, 76), (108, 77), (108, 78), (108, 79), (108, 80), (108, 81), (108, 82), (108, 83), (108, 84), (108, 85), (108, 86), (108, 87), (108, 88), (108, 89), (108, 90), (108, 93), (108, 94), (108, 95), (108, 96), (108, 97), (108, 98), (108, 99), (108, 100), (108, 101), (108, 103), (109, 68), (109, 70), (109, 71), (109, 72), (109, 73), (109, 74), (109, 75), (109, 76), (109, 77), (109, 79), (109, 80), (109, 81), (109, 82), (109, 83),
(109, 84), (109, 85), (109, 86), (109, 87), (109, 88), (109, 89), (109, 97), (109, 99), (109, 100), (109, 101), (109, 103), (110, 69), (110, 71), (110, 72), (110, 73), (110, 74), (110, 75), (110, 76), (110, 78), (110, 81), (110, 82), (110, 83), (110, 84), (110, 85), (110, 86), (110, 87), (110, 88), (110, 90), (110, 97), (110, 99), (110, 100), (110, 101), (110, 102), (110, 104), (111, 70), (111, 72), (111, 73), (111, 74), (111, 75), (111, 77), (111, 82), (111, 83), (111, 84), (111, 85), (111, 86), (111, 87), (111, 89), (111, 98), (111, 100), (111, 101), (111, 102), (111, 103), (111, 105), (112, 71), (112, 73), (112, 74), (112, 76), (112, 81), (112, 83), (112, 84), (112, 85), (112, 86), (112, 87), (112, 89), (112, 98), (112, 100), (112, 101), (112, 102), (112, 103), (112, 106), (113, 71), (113, 73),
(113, 75), (113, 82), (113, 84), (113, 85), (113, 86), (113, 88), (113, 98), (113, 100), (113, 101), (113, 102), (113, 104), (113, 105), (113, 107), (114, 71), (114, 74), (114, 82), (114, 84), (114, 85), (114, 86), (114, 88), (114, 97), (114, 99), (114, 100), (114, 101), (114, 103), (114, 107), (115, 70), (115, 72), (115, 74), (115, 83), (115, 85), (115, 86), (115, 88), (115, 97), (115, 99), (115, 100), (115, 102), (115, 107), (116, 70), (116, 73), (116, 83), (116, 85), (116, 87), (116, 96), (116, 102), (116, 108), (117, 70), (117, 73), (117, 84), (117, 87), (117, 96), (117, 97), (117, 100), (117, 108), (118, 69), (118, 72), (118, 85), (118, 86), (118, 108), (118, 109), (119, 109), (120, 109), (120, 114), (120, 115), )
coordinates_FEDAB9 = ((126, 65),
(126, 66), (127, 65), (127, 67), (128, 65), (128, 67), (129, 68), )
coordinates_FFDAB9 = ((100, 66),
(100, 67), (100, 68), (100, 69), (100, 71), (100, 78), (100, 80), (100, 81), (100, 83), (101, 64), (101, 65), (101, 72), (101, 77), (101, 82), (102, 63), (102, 70), (102, 71), (102, 74), (102, 75), (102, 78), (102, 79), (103, 62), (103, 64), (103, 67), (103, 68), (103, 69), (103, 73), (103, 74), (103, 75), (103, 77), (104, 61), (104, 63), (104, 64), (104, 65), (104, 66), (105, 62), (105, 64), (106, 63), (107, 61), (107, 63), (107, 64), (108, 62), (108, 64), (108, 65), (109, 62), (109, 66), (110, 63), (110, 67), (111, 64), (111, 68), (112, 65), (112, 69), (113, 66), (113, 69), (114, 66), (114, 68), (115, 66), (115, 68), (116, 66), (116, 68), (117, 66), (117, 67), (118, 65), (118, 67), (119, 65), (119, 67), (120, 66), )
coordinates_771286 = ((126, 111),
(126, 112), (127, 111), (127, 112), (128, 110), (128, 112), (129, 110), (129, 111), (130, 109), (130, 111), (131, 108), (131, 110), (132, 108), (132, 110), (133, 107), (133, 109), (134, 106), (134, 109), (135, 105), (135, 107), (135, 109), (136, 105), (136, 108), (137, 104), (137, 108), (138, 104), (138, 106), )
coordinates_781286 = ((105, 104),
(106, 104), (106, 106), (107, 104), (107, 108), (108, 105), (108, 109), (109, 106), (109, 108), (109, 110), (110, 106), (110, 110), (111, 107), (111, 110), (112, 108), (112, 111), (113, 109), (113, 111), (114, 109), (114, 111), (115, 110), (115, 112), (116, 110), (116, 112), (117, 110), (117, 112), (117, 113), (118, 111), (118, 113), (119, 112), )
coordinates_79BADC = ((138, 109),
(139, 107), (139, 108), )
coordinates_CD3E4E = ()
coordinates_ED0000 = ((130, 63),
(130, 65), (131, 62), (131, 66), (131, 68), (132, 62), (132, 65), (132, 66), (132, 68), (133, 62), (133, 64), (134, 61), (134, 63), (135, 61), (135, 63), (136, 62), (136, 64), (137, 63), (137, 66), (138, 63), (138, 67), (138, 69), (139, 63), (139, 64), (139, 65), (139, 66), (139, 70), (140, 63), (140, 65), (140, 68), (140, 69), (141, 63), (141, 66), (142, 63), (142, 65), (143, 63), (143, 64), (144, 63), (144, 64), (145, 63), (145, 76), (145, 77), (146, 63), (146, 65), (146, 66), (146, 71), (146, 72), (146, 73), (146, 74), (146, 75), (146, 78), (146, 80), (147, 64), (147, 67), (147, 68), (147, 69), (147, 70), (147, 76), (147, 78), (148, 65), (148, 71), (148, 72), (148, 73), (148, 74), (148, 75), (148, 77), (149, 66), (149, 68), (149, 69), (149, 70), (149, 71), (149, 76), (150, 66),
(150, 68), (150, 69), (150, 72), (150, 73), (150, 75), (151, 66), (151, 68), (151, 71), (152, 66), (152, 69), (153, 66), (153, 68), (153, 86), (153, 88), (153, 90), (154, 66), (154, 68), (154, 85), (154, 89), (155, 67), (155, 69), (155, 84), (155, 86), (155, 88), (156, 67), (156, 71), (156, 82), (156, 85), (156, 88), (157, 69), (157, 71), (157, 78), (157, 80), (157, 87), (158, 68), (158, 71), (158, 77), (158, 81), (158, 85), (159, 69), (159, 72), (159, 76), (159, 78), (159, 79), (159, 83), (160, 70), (160, 74), (160, 81), (161, 71), (161, 73), (161, 74), (161, 75), (161, 76), (161, 77), (161, 78), )
coordinates_7ABADC = ((104, 107),
(104, 109), (105, 107), (106, 109), (106, 110), )
coordinates_EC0DB0 = ((93, 128),
(93, 130), (94, 122), (94, 124), (94, 125), (94, 127), )
coordinates_EB0DB0 = ((150, 120),
(150, 122), (150, 123), (150, 124), (150, 125), (150, 127), (151, 121), (151, 122), (151, 123), (151, 124), (151, 125), )
coordinates_ED82EE = ((124, 67),
(124, 69), (124, 73), (124, 79), (124, 81), (124, 82), (124, 84), (125, 70), (125, 71), (125, 75), (125, 78), (125, 79), (125, 85), (126, 73), (126, 74), (126, 75), (126, 76), (126, 77), (126, 81), (126, 82), (126, 83), (126, 85), (127, 81), (127, 83), (127, 85), (128, 82), (128, 85), (129, 82), (129, 84), (129, 85), (129, 86), (130, 82), (130, 84), (130, 86), (131, 82), (131, 84), (131, 85), (131, 86), (131, 88), (132, 83), (132, 86), (132, 89), (133, 84), (133, 90), (134, 86), (134, 88), (135, 89), (135, 91), )
coordinates_EE82EE = ((110, 93),
(110, 94), (111, 92), (111, 94), (112, 91), (112, 93), (113, 77), (113, 79), (113, 91), (113, 93), (114, 77), (114, 80), (114, 90), (115, 76), (115, 78), (115, 80), (115, 90), (115, 92), (116, 76), (116, 78), (116, 79), (116, 81), (116, 90), (116, 91), (117, 75), (117, 77), (117, 78), (117, 79), (117, 81), (117, 89), (117, 91), (118, 76), (118, 77), (118, 80), (118, 82), (118, 88), (118, 90), (119, 74), (119, 75), (119, 78), (119, 79), (119, 81), (119, 83), (119, 87), (119, 90), (120, 68), (120, 70), (120, 71), (120, 72), (120, 74), (120, 76), (120, 80), (120, 82), (120, 85), (120, 86), (120, 88), (120, 90), (121, 68), (121, 75), (121, 81), (122, 68), (122, 74), (122, 81), (122, 83), (122, 84), (122, 85), (122, 86), (122, 87), (122, 89), (123, 71), )
coordinates_9832CC = ((123, 98),
(123, 99), (123, 100), (123, 101), (123, 102), (123, 103), (123, 104), (123, 105), (123, 107), (124, 87), (124, 89), (124, 90), (124, 91), (124, 92), (124, 93), (124, 94), (124, 95), (124, 96), (124, 106), (125, 87), (125, 99), (125, 100), (125, 101), (125, 103), (125, 104), (125, 106), (126, 87), (126, 89), (126, 90), (126, 91), (126, 92), (126, 98), (126, 103), (126, 104), (126, 106), (127, 88), (127, 91), (127, 95), (127, 96), (127, 103), (127, 106), (128, 89), (128, 91), (128, 103), (128, 105), (129, 91), (129, 103), (129, 105), (130, 90), (130, 92), (131, 90), (131, 92), (132, 91), (132, 93), (133, 92), (133, 94), (134, 93), (134, 94), (135, 94), )
coordinates_9932CC = ((112, 96),
(113, 95), (114, 95), (115, 94), (115, 105), (116, 94), (116, 104), (116, 106), (117, 93), (117, 94), (117, 104), (117, 106), (118, 93), (118, 95), (118, 102), (118, 104), (118, 106), (119, 92), (119, 94), (119, 96), (119, 97), (119, 98), (119, 99), (119, 100), (119, 106), (120, 92), (120, 100), (120, 101), (120, 102), (120, 103), (120, 104), (120, 107), (121, 92), (121, 94), (121, 96), (121, 100), (121, 104), (121, 108), )
coordinates_EE0000 = ((74, 88),
(74, 90), (74, 92), (75, 87), (75, 94), (76, 86), (76, 88), (76, 89), (76, 90), (76, 91), (76, 92), (76, 95), (77, 85), (77, 87), (77, 88), (77, 89), (77, 90), (77, 91), (77, 92), (77, 93), (77, 94), (77, 96), (78, 84), (78, 86), (78, 87), (78, 88), (78, 89), (78, 90), (78, 91), (78, 92), (78, 93), (78, 94), (78, 95), (78, 97), (79, 85), (79, 86), (79, 87), (79, 88), (79, 89), (79, 90), (79, 91), (79, 92), (79, 93), (79, 94), (79, 95), (79, 97), (80, 73), (80, 76), (80, 81), (80, 84), (80, 85), (80, 86), (80, 87), (80, 88), (80, 89), (80, 90), (80, 91), (80, 92), (80, 93), (80, 94), (80, 95), (80, 97), (81, 72), (81, 77), (81, 78), (81, 82), (81, 83), (81, 84), (81, 85), (81, 86), (81, 87), (81, 88), (81, 89),
(81, 90), (81, 91), (81, 92), (81, 93), (81, 94), (81, 95), (81, 96), (81, 98), (82, 71), (82, 73), (82, 75), (82, 76), (82, 79), (82, 81), (82, 82), (82, 83), (82, 84), (82, 85), (82, 86), (82, 87), (82, 88), (82, 89), (82, 90), (82, 91), (82, 92), (82, 93), (82, 94), (82, 95), (82, 96), (82, 98), (83, 70), (83, 72), (83, 74), (83, 77), (83, 80), (83, 81), (83, 82), (83, 83), (83, 84), (83, 85), (83, 86), (83, 87), (83, 88), (83, 89), (83, 90), (83, 91), (83, 92), (83, 93), (83, 94), (83, 95), (83, 96), (83, 98), (84, 70), (84, 73), (84, 78), (84, 81), (84, 82), (84, 83), (84, 84), (84, 85), (84, 86), (84, 87), (84, 88), (84, 89), (84, 90), (84, 91), (84, 92), (84, 93), (84, 94), (84, 95), (84, 96), (84, 98),
(85, 69), (85, 72), (85, 80), (85, 82), (85, 83), (85, 84), (85, 85), (85, 86), (85, 87), (85, 88), (85, 89), (85, 90), (85, 91), (85, 92), (85, 93), (85, 94), (85, 95), (85, 96), (86, 68), (86, 71), (86, 81), (86, 84), (86, 85), (86, 86), (86, 87), (86, 88), (86, 89), (86, 90), (86, 91), (86, 92), (86, 93), (86, 94), (86, 98), (87, 68), (87, 70), (87, 82), (87, 86), (87, 87), (87, 88), (87, 89), (87, 90), (87, 91), (87, 92), (87, 96), (88, 68), (88, 70), (88, 84), (88, 94), (89, 68), (89, 70), (89, 86), (89, 88), (89, 89), (89, 90), (89, 92), (90, 68), (90, 71), (91, 68), (91, 70), (91, 72), (92, 69), (92, 71), (92, 73), (93, 70), (93, 75), (94, 71), (94, 77), (95, 72), (95, 79), (96, 74), (96, 77), (96, 81),
(97, 76), (97, 82), (98, 77), (98, 79), (98, 80), (98, 81), (98, 83), )
coordinates_FE4500 = ((153, 113),
(153, 115), (154, 114), (154, 116), (155, 115), (155, 118), (155, 119), (155, 120), (155, 121), (155, 122), (155, 123), (155, 124), (155, 125), (156, 116), (156, 120), (156, 126), (156, 128), (157, 117), (157, 129), (158, 122), (158, 124), (158, 125), (158, 126), (158, 127), )
coordinates_FED700 = ((160, 124),
(160, 126), (160, 127), (160, 129), (161, 126), (161, 128), )
coordinates_CF2090 = ((164, 132),
(164, 134), (165, 131), (165, 133), (166, 130), (166, 132), (167, 130), (167, 132), (168, 129), (168, 131), (169, 129), (169, 131), (170, 129), (170, 131), (171, 128), (171, 130), (172, 128), (172, 130), (173, 128), (173, 130), (174, 128), (174, 130), (175, 128), (175, 130), (176, 128), (176, 130), (177, 128), (177, 130), (178, 128), (178, 129), (179, 129), (180, 129), (181, 128), (181, 129), (182, 128), (183, 128), (184, 128), (185, 127), (185, 128), (186, 127), (186, 128), (187, 122), (187, 123), (187, 126), (187, 128), (188, 122), (188, 127), (188, 129), (189, 122), (189, 124), (189, 126), )
coordinates_EFE68C = ((165, 136),
(165, 137), (166, 135), (166, 138), (167, 134), (167, 136), (167, 138), (168, 134), (168, 136), (168, 137), (168, 139), (169, 133), (169, 135), (169, 136), (169, 137), (169, 139), (170, 133), (170, 135), (170, 136), (170, 137), (170, 138), (170, 140), (171, 133), (171, 135), (171, 136), (171, 137), (171, 138), (171, 140), (172, 132), (172, 134), (172, 135), (172, 136), (172, 137), (172, 139), (173, 132), (173, 134), (173, 135), (173, 136), (173, 137), (173, 139), (174, 132), (174, 134), (174, 135), (174, 136), (174, 138), (175, 132), (175, 134), (175, 135), (175, 137), (176, 132), (176, 134), (176, 136), (177, 132), (177, 135), (178, 132), (178, 134), (179, 131), (179, 134), (180, 131), (180, 134), (180, 144), (181, 131), (181, 134), (181, 144), (182, 131), (182, 133), (182, 134), (182, 137), (182, 138), (182, 139), (182, 144), (182, 145), (183, 130),
(183, 132), (183, 133), (183, 134), (183, 139), (183, 144), (184, 130), (184, 132), (184, 133), (184, 134), (184, 135), (184, 136), (184, 137), (184, 139), (184, 145), (185, 130), (185, 132), (185, 133), (185, 134), (185, 135), (185, 136), (185, 137), (185, 139), (185, 143), (185, 145), (186, 130), (186, 132), (186, 133), (186, 134), (186, 135), (186, 136), (186, 137), (186, 138), (186, 139), (186, 142), (186, 145), (187, 130), (187, 132), (187, 133), (187, 134), (187, 135), (187, 136), (187, 137), (187, 138), (187, 139), (187, 140), (187, 141), (187, 144), (187, 145), (188, 131), (188, 135), (188, 136), (189, 131), (189, 133), (189, 134), (189, 137), (189, 138), (189, 139), (189, 140), (189, 142), )
coordinates_31CD32 = ((162, 149),
(162, 151), (163, 146), (163, 152), (164, 146), (164, 148), (164, 150), (164, 151), (164, 154), (165, 149), (165, 151), (165, 152), (165, 154), (166, 150), (166, 152), (166, 154), (167, 151), (167, 154), (168, 152), (168, 155), (169, 153), (169, 154), (169, 157), (170, 154), (170, 157), (171, 154), (171, 156), (172, 154), (172, 156), (173, 148), (173, 154), (173, 155), (174, 148), (174, 154), (174, 155), (175, 148), (175, 150), (175, 154), (175, 155), (176, 148), (176, 151), (176, 154), (176, 156), (177, 148), (177, 150), (177, 153), (177, 154), (177, 156), (178, 147), (178, 148), (178, 149), (178, 150), (178, 151), (178, 154), (178, 156), (179, 145), (179, 148), (179, 149), (179, 150), (179, 151), (179, 152), (179, 153), (179, 154), (179, 156), (180, 146), (180, 148), (180, 149), (180, 150), (180, 151), (180, 152), (180, 153), (180, 154), (180, 156),
(181, 147), (181, 149), (181, 150), (181, 151), (181, 152), (181, 153), (181, 155), (182, 147), (182, 155), (183, 148), (183, 150), (183, 151), (183, 152), (183, 154), )
coordinates_FFD700 = ((83, 132),
(84, 132), (85, 132), )
coordinates_D02090 = ((57, 130),
(58, 127), (58, 129), (58, 130), (58, 132), (59, 125), (59, 132), (60, 126), (60, 127), (60, 130), (60, 132), (61, 131), (61, 132), (62, 132), (63, 132), (64, 132), (65, 132), (65, 133), (66, 132), (66, 133), (67, 132), (67, 133), (68, 132), (68, 133), (69, 132), (69, 133), (70, 132), (70, 133), (71, 132), (71, 133), (72, 132), (73, 132), (73, 134), (74, 132), (74, 134), (75, 132), (75, 134), (76, 132), (76, 135), (77, 133), (77, 135), (78, 134), (78, 136), (79, 136), )
coordinates_F0E68C = ((57, 134),
(57, 136), (57, 137), (57, 138), (57, 139), (57, 141), (58, 134), (58, 136), (58, 142), (59, 134), (59, 136), (59, 137), (59, 138), (59, 140), (59, 142), (60, 134), (60, 136), (60, 140), (60, 142), (61, 134), (61, 136), (61, 140), (61, 143), (62, 135), (62, 136), (62, 141), (62, 143), (63, 135), (63, 136), (63, 141), (63, 144), (64, 135), (64, 136), (64, 141), (64, 144), (65, 135), (65, 136), (65, 142), (65, 144), (66, 135), (66, 136), (66, 142), (66, 144), (67, 135), (67, 137), (67, 143), (68, 135), (68, 137), (68, 144), (68, 145), (69, 135), (69, 137), (69, 144), (69, 145), (70, 135), (70, 137), (70, 144), (70, 145), (71, 136), (71, 137), (71, 144), (71, 145), (72, 136), (72, 137), (72, 145), (73, 136), (73, 138), (74, 136), (74, 138), (75, 137), (75, 138), (76, 137), )
coordinates_32CD32 = ((59, 148),
(59, 150), (59, 151), (60, 146), (60, 152), (60, 154), (61, 146), (61, 148), (61, 149), (61, 155), (62, 146), (62, 148), (62, 149), (62, 151), (62, 153), (62, 154), (62, 157), (63, 146), (63, 149), (63, 152), (63, 154), (63, 155), (63, 157), (64, 147), (64, 149), (64, 153), (64, 155), (64, 157), (65, 148), (65, 154), (65, 157), (66, 148), (66, 153), (66, 156), (67, 148), (67, 153), (67, 155), (68, 148), (68, 152), (68, 155), (69, 147), (69, 152), (69, 155), (70, 147), (70, 152), (70, 153), (70, 154), (70, 156), (71, 147), (71, 152), (71, 154), (71, 155), (71, 157), (72, 152), (72, 154), (72, 155), (72, 156), (72, 158), (73, 153), (73, 155), (73, 158), (74, 153), (74, 156), (75, 154), (75, 155), (76, 154), (76, 155), (77, 154), (77, 156), (78, 155), (78, 156), (79, 154), (79, 157),
(80, 147), (80, 149), (80, 150), (80, 151), (80, 152), (80, 153), (80, 154), (80, 155), (80, 156), (80, 158), (81, 152), (81, 155), (81, 156), (81, 158), (82, 154), (82, 158), (83, 155), (83, 158), )
coordinates_01FF7F = ((154, 92),
(154, 94), (155, 91), (155, 95), (156, 90), (156, 92), (156, 93), (156, 95), (157, 89), (157, 91), (157, 92), (157, 93), (157, 94), (157, 96), (158, 88), (158, 92), (158, 93), (158, 94), (158, 96), (159, 87), (159, 93), (159, 94), (159, 96), (160, 85), (160, 89), (160, 92), (160, 94), (160, 96), (161, 83), (161, 88), (161, 93), (161, 96), (162, 80), (162, 81), (162, 82), (162, 85), (162, 87), (162, 94), (162, 96), (163, 75), (163, 77), (163, 78), (163, 79), (163, 83), (163, 84), (163, 86), (164, 75), (164, 79), (164, 80), (164, 85), (165, 75), (165, 77), (165, 81), (165, 82), (165, 84), (166, 75), (166, 77), (167, 75), (167, 77), (167, 89), (167, 90), (167, 91), (167, 92), (167, 94), (168, 76), (168, 78), (168, 86), (168, 87), (168, 93), (169, 77), (169, 79), (169, 84), (169, 85),
(169, 88), (169, 89), (169, 90), (169, 92), (170, 78), (170, 80), (170, 83), (170, 86), (170, 87), (170, 88), (170, 89), (170, 91), (171, 79), (171, 84), (171, 85), (171, 86), (171, 87), (171, 88), (171, 89), (171, 91), (171, 98), (171, 101), (172, 80), (172, 83), (172, 84), (172, 85), (172, 86), (172, 87), (172, 88), (172, 89), (172, 90), (172, 91), (172, 97), (172, 100), (173, 82), (173, 87), (173, 88), (173, 89), (173, 91), (173, 96), (173, 99), (174, 83), (174, 85), (174, 88), (174, 89), (174, 91), (174, 95), (174, 98), (175, 87), (175, 89), (175, 90), (175, 91), (175, 93), (175, 94), (175, 98), (176, 88), (176, 90), (176, 91), (176, 97), (177, 89), (177, 91), (177, 92), (177, 95), (178, 90), (178, 94), (179, 91), )
coordinates_CCB68E = ((121, 128),
(122, 126), (122, 129), )
coordinates_FF4500 = ((84, 117),
(84, 119), (85, 115), (85, 120), (86, 114), (86, 117), (86, 118), (86, 119), (86, 121), (87, 113), (87, 119), (87, 120), (87, 122), (87, 129), (87, 131), (88, 113), (88, 115), (88, 116), (88, 117), (88, 118), (88, 123), (88, 127), (88, 129), (89, 119), (89, 121), (89, 122), (89, 123), (89, 124), (89, 125), (89, 126), )
coordinates_A42A2A = ((98, 134),
(99, 134), (99, 136), (100, 134), (100, 136), (101, 133), (101, 135), (101, 137), (102, 133), (102, 135), (102, 137), (103, 133), (103, 135), (103, 137), (104, 133), (104, 135), (104, 137), (105, 133), (105, 135), (105, 136), (105, 138), (106, 133), (106, 135), (106, 136), (106, 138), (107, 133), (107, 135), (107, 136), (107, 137), (107, 139), (108, 133), (108, 135), (108, 136), (108, 137), (108, 138), (108, 140), (109, 133), (109, 135), (109, 136), (109, 137), (109, 138), (109, 139), (109, 142), (110, 132), (110, 134), (110, 135), (110, 136), (110, 137), (110, 138), (110, 139), (110, 140), (110, 143), (110, 144), (110, 145), (111, 131), (111, 133), (111, 134), (111, 135), (111, 136), (111, 137), (111, 138), (111, 139), (111, 140), (111, 141), (111, 142), (111, 144), (112, 131), (112, 133), (112, 134), (112, 135), (112, 136), (112, 137), (112, 138),
(112, 139), (112, 140), (112, 141), (112, 142), (112, 144), (113, 130), (113, 132), (113, 133), (113, 134), (113, 135), (113, 136), (113, 137), (113, 138), (113, 139), (113, 140), (113, 141), (113, 142), (113, 144), (114, 130), (114, 132), (114, 133), (114, 134), (114, 135), (114, 136), (114, 137), (114, 138), (114, 139), (114, 140), (114, 141), (114, 143), (115, 130), (115, 132), (115, 133), (115, 134), (115, 135), (115, 136), (115, 137), (115, 138), (115, 139), (115, 140), (115, 141), (115, 143), (116, 129), (116, 131), (116, 132), (116, 133), (116, 134), (116, 135), (116, 136), (116, 137), (116, 138), (116, 139), (116, 140), (116, 141), (116, 143), (117, 129), (117, 131), (117, 132), (117, 133), (117, 134), (117, 135), (117, 136), (117, 137), (117, 138), (117, 139), (117, 140), (117, 142), (118, 130), (118, 132), (118, 133), (118, 134), (118, 135),
(118, 136), (118, 137), (118, 138), (118, 139), (118, 140), (118, 142), (119, 130), (119, 133), (119, 134), (119, 135), (119, 136), (119, 137), (119, 138), (119, 139), (119, 140), (119, 142), (120, 131), (120, 142), (121, 131), (121, 133), (121, 134), (121, 135), (121, 136), (121, 137), (121, 138), (121, 139), (121, 140), (121, 142), )
coordinates_A42A29 = ((123, 131),
(123, 133), (123, 134), (123, 135), (123, 136), (123, 137), (123, 138), (123, 140), (124, 130), (124, 139), (124, 140), (124, 142), (125, 130), (125, 132), (125, 133), (125, 134), (125, 135), (125, 136), (125, 137), (125, 138), (125, 142), (126, 131), (126, 133), (126, 134), (126, 135), (126, 136), (126, 137), (126, 138), (126, 139), (126, 140), (126, 142), (127, 131), (127, 133), (127, 134), (127, 135), (127, 136), (127, 137), (127, 138), (127, 139), (127, 140), (127, 142), (128, 131), (128, 133), (128, 134), (128, 135), (128, 136), (128, 137), (128, 138), (128, 139), (128, 140), (128, 142), (129, 131), (129, 133), (129, 134), (129, 135), (129, 136), (129, 137), (129, 138), (129, 139), (129, 140), (129, 142), (130, 132), (130, 134), (130, 135), (130, 136), (130, 137), (130, 138), (130, 139), (130, 140), (130, 141), (130, 143), (131, 132), (131, 134),
(131, 135), (131, 136), (131, 137), (131, 138), (131, 139), (131, 140), (131, 141), (131, 143), (132, 133), (132, 135), (132, 136), (132, 137), (132, 138), (132, 139), (132, 140), (132, 141), (132, 143), (133, 133), (133, 135), (133, 136), (133, 137), (133, 138), (133, 139), (133, 140), (133, 141), (133, 143), (134, 134), (134, 136), (134, 137), (134, 138), (134, 139), (134, 140), (134, 141), (134, 143), (135, 134), (135, 136), (135, 137), (135, 138), (135, 139), (135, 140), (135, 141), (135, 144), (136, 134), (136, 135), (136, 136), (136, 137), (136, 138), (136, 139), (136, 140), (136, 142), (137, 134), (137, 136), (137, 137), (137, 138), (137, 139), (137, 141), (138, 134), (138, 136), (138, 137), (138, 138), (138, 140), (139, 134), (139, 136), (139, 137), (139, 139), (140, 133), (140, 135), (140, 136), (140, 138), (141, 134), (141, 136), (141, 138),
(142, 134), (142, 137), (143, 134), (143, 137), (144, 134), (144, 137), (145, 135), (145, 136), )
coordinates_00FF7F = ((61, 97),
(61, 99), (62, 94), (62, 95), (62, 96), (62, 100), (62, 102), (63, 90), (63, 92), (63, 93), (63, 103), (64, 88), (64, 89), (64, 93), (64, 94), (64, 95), (64, 96), (64, 97), (64, 100), (65, 87), (65, 89), (65, 90), (65, 91), (65, 94), (65, 95), (65, 97), (65, 101), (65, 104), (66, 85), (66, 96), (67, 84), (67, 87), (67, 94), (67, 97), (68, 83), (68, 86), (68, 87), (68, 95), (69, 82), (69, 84), (69, 85), (69, 87), (69, 96), (69, 98), (70, 84), (70, 85), (70, 86), (70, 87), (70, 89), (71, 81), (71, 83), (71, 84), (71, 85), (71, 86), (71, 87), (71, 90), (71, 91), (71, 92), (72, 80), (72, 82), (72, 83), (72, 84), (72, 85), (72, 88), (72, 92), (72, 93), (72, 95), (73, 80), (73, 82), (73, 83), (73, 84), (73, 87), (73, 94),
(73, 96), (74, 79), (74, 81), (74, 82), (74, 83), (74, 97), (75, 79), (75, 81), (75, 82), (75, 84), (75, 97), (75, 98), (76, 79), (76, 81), (76, 83), (76, 98), (77, 80), (77, 82), (77, 99), (78, 81), (78, 99), (79, 100), (80, 100), (81, 100), (82, 100), (83, 100), (84, 100), )
coordinates_01760E = ((123, 121),
(123, 124), (124, 119), (124, 125), (125, 116), (125, 118), (125, 121), (125, 122), (125, 123), (125, 124), (125, 128), (126, 115), (126, 119), (126, 120), (126, 121), (126, 122), (126, 123), (126, 124), (126, 125), (126, 126), (126, 128), (127, 115), (127, 117), (127, 118), (127, 119), (127, 120), (127, 121), (127, 122), (127, 123), (127, 124), (127, 125), (127, 126), (127, 127), (127, 128), (127, 129), (128, 114), (128, 116), (128, 117), (128, 118), (128, 119), (128, 120), (128, 121), (128, 122), (128, 123), (128, 124), (128, 125), (128, 126), (128, 127), (128, 129), (129, 114), (129, 116), (129, 117), (129, 118), (129, 119), (129, 120), (129, 121), (129, 122), (129, 123), (129, 124), (129, 125), (129, 126), (129, 127), (129, 129), (130, 113), (130, 115), (130, 116), (130, 117), (130, 118), (130, 119), (130, 120), (130, 121), (130, 122), (130, 123),
(130, 124), (130, 125), (130, 126), (130, 127), (130, 128), (130, 130), (131, 113), (131, 115), (131, 116), (131, 117), (131, 118), (131, 119), (131, 120), (131, 121), (131, 122), (131, 123), (131, 124), (131, 125), (131, 126), (131, 127), (131, 128), (131, 130), (132, 112), (132, 114), (132, 115), (132, 116), (132, 117), (132, 118), (132, 119), (132, 120), (132, 121), (132, 122), (132, 123), (132, 124), (132, 125), (132, 126), (132, 127), (132, 128), (132, 129), (132, 131), (133, 112), (133, 114), (133, 115), (133, 116), (133, 117), (133, 118), (133, 119), (133, 120), (133, 121), (133, 122), (133, 123), (133, 124), (133, 125), (133, 126), (133, 127), (133, 128), (133, 129), (133, 131), (134, 111), (134, 113), (134, 114), (134, 115), (134, 116), (134, 117), (134, 118), (134, 119), (134, 120), (134, 121), (134, 122), (134, 123), (134, 124), (134, 125),
(134, 126), (134, 127), (134, 128), (134, 129), (134, 130), (134, 132), (135, 111), (135, 113), (135, 114), (135, 115), (135, 116), (135, 117), (135, 118), (135, 119), (135, 120), (135, 121), (135, 122), (135, 123), (135, 124), (135, 125), (135, 126), (135, 127), (135, 128), (135, 129), (135, 130), (135, 132), (136, 112), (136, 114), (136, 115), (136, 116), (136, 117), (136, 118), (136, 119), (136, 120), (136, 121), (136, 122), (136, 123), (136, 124), (136, 125), (136, 126), (136, 127), (136, 128), (136, 129), (136, 130), (136, 132), (137, 113), (137, 115), (137, 116), (137, 117), (137, 118), (137, 119), (137, 120), (137, 121), (137, 122), (137, 123), (137, 124), (137, 125), (137, 126), (137, 127), (137, 128), (137, 129), (137, 130), (137, 132), (138, 116), (138, 117), (138, 118), (138, 119), (138, 120), (138, 121), (138, 122), (138, 123), (138, 124),
(138, 125), (138, 126), (138, 127), (138, 128), (138, 129), (138, 130), (138, 132), (139, 115), (139, 117), (139, 118), (139, 119), (139, 120), (139, 121), (139, 122), (139, 123), (139, 124), (139, 125), (139, 126), (139, 127), (139, 128), (139, 129), (139, 131), (140, 116), (140, 119), (140, 120), (140, 121), (140, 122), (140, 123), (140, 124), (140, 125), (140, 126), (140, 127), (140, 128), (140, 129), (140, 131), (141, 117), (141, 124), (141, 125), (141, 126), (141, 127), (141, 128), (142, 119), (142, 121), (142, 122), (142, 123), (142, 129), (142, 130), (142, 132), (143, 124), (143, 126), (143, 127), (143, 128), )
coordinates_FF6347 = ((91, 147),
(91, 148), (92, 147), (92, 149), (92, 150), (92, 151), (92, 153), (93, 148), (93, 153), (94, 149), (94, 151), (94, 153), (95, 149), (95, 151), (95, 153), (96, 150), (96, 153), (97, 151), (97, 153), (98, 151), (99, 152), (100, 150), (100, 152), (101, 149), (101, 151), (102, 148), (102, 151), (103, 148), (103, 150), (104, 142), (104, 149), (105, 142), (105, 145), (105, 148), (106, 143), (106, 145), )
coordinates_DBD814 = ((143, 141),
(144, 140), (144, 142), (145, 138), (145, 142), (146, 137), (146, 140), (146, 141), (146, 143), (147, 138), (147, 140), (147, 141), (147, 143), (148, 138), (148, 140), (148, 141), (148, 142), (148, 144), (149, 138), (149, 140), (149, 141), (149, 142), (149, 144), (150, 138), (150, 140), (150, 141), (150, 142), (150, 144), (151, 138), (151, 140), (151, 141), (151, 142), (151, 144), (152, 138), (152, 140), (152, 141), (152, 143), (153, 138), (153, 140), (153, 142), (154, 141), (155, 139), (155, 141), )
coordinates_DCD814 = ((90, 142),
(91, 139), (91, 142), (92, 139), (92, 143), (93, 138), (93, 140), (93, 141), (93, 142), (93, 144), (94, 138), (94, 140), (94, 141), (94, 142), (94, 143), (94, 145), (95, 138), (95, 140), (95, 141), (95, 142), (95, 143), (95, 144), (95, 146), (96, 138), (96, 140), (96, 141), (96, 142), (96, 143), (96, 144), (96, 146), (97, 138), (97, 140), (97, 141), (97, 142), (97, 143), (98, 138), (98, 140), (98, 141), (98, 142), (98, 143), (98, 145), (99, 140), (99, 142), (99, 144), (100, 140), (100, 143), (101, 140), (101, 142), (102, 140), (102, 142), (103, 140), (103, 141), )
coordinates_FE6347 = ((139, 144),
(139, 145), (140, 143), (140, 145), (140, 146), (140, 147), (141, 142), (141, 147), (141, 148), (142, 148), (143, 149), (145, 150), (146, 151), (147, 150), (147, 151), (148, 150), (148, 152), (149, 149), (149, 152), (150, 148), (150, 150), (150, 153), (151, 147), (151, 151), (151, 153), (152, 147), (152, 150), (153, 146), (153, 148), (154, 145), (154, 146), (155, 145), )
coordinates_C33AFA = ((157, 141),
)
coordinates_C43AFA = ((88, 141),
(89, 140), )
coordinates_00760E = ((99, 127),
(99, 128), (99, 130), (100, 122), (100, 123), (100, 124), (100, 125), (100, 126), (100, 131), (101, 119), (101, 121), (101, 127), (101, 128), (101, 129), (101, 131), (102, 116), (102, 117), (102, 122), (102, 123), (102, 124), (102, 125), (102, 126), (102, 127), (102, 128), (102, 129), (102, 131), (103, 115), (103, 119), (103, 120), (103, 121), (103, 122), (103, 123), (103, 124), (103, 125), (103, 126), (103, 127), (103, 128), (103, 129), (103, 131), (104, 114), (104, 117), (104, 118), (104, 119), (104, 120), (104, 121), (104, 122), (104, 123), (104, 124), (104, 125), (104, 126), (104, 127), (104, 128), (104, 129), (104, 131), (105, 113), (105, 115), (105, 116), (105, 117), (105, 118), (105, 119), (105, 120), (105, 121), (105, 122), (105, 123), (105, 124), (105, 125), (105, 126), (105, 127), (105, 128), (105, 129), (105, 131), (106, 114), (106, 115),
(106, 116), (106, 117), (106, 118), (106, 119), (106, 120), (106, 121), (106, 122), (106, 123), (106, 124), (106, 125), (106, 126), (106, 127), (106, 128), (106, 129), (106, 131), (107, 112), (107, 114), (107, 115), (107, 116), (107, 117), (107, 118), (107, 119), (107, 120), (107, 121), (107, 122), (107, 123), (107, 124), (107, 125), (107, 126), (107, 127), (107, 128), (107, 129), (107, 131), (108, 112), (108, 114), (108, 115), (108, 116), (108, 117), (108, 118), (108, 119), (108, 120), (108, 121), (108, 122), (108, 123), (108, 124), (108, 125), (108, 126), (108, 127), (108, 128), (108, 129), (108, 131), (109, 112), (109, 114), (109, 115), (109, 116), (109, 117), (109, 118), (109, 119), (109, 120), (109, 121), (109, 122), (109, 123), (109, 124), (109, 125), (109, 126), (109, 127), (109, 128), (109, 130), (110, 112), (110, 114), (110, 115), (110, 116),
(110, 117), (110, 118), (110, 119), (110, 120), (110, 121), (110, 122), (110, 123), (110, 124), (110, 125), (110, 126), (110, 127), (110, 129), (111, 113), (111, 115), (111, 116), (111, 117), (111, 118), (111, 119), (111, 120), (111, 121), (111, 122), (111, 123), (111, 124), (111, 125), (111, 126), (111, 127), (111, 129), (112, 113), (112, 115), (112, 116), (112, 117), (112, 118), (112, 119), (112, 120), (112, 121), (112, 122), (112, 123), (112, 124), (112, 125), (112, 126), (112, 128), (113, 113), (113, 115), (113, 116), (113, 117), (113, 118), (113, 119), (113, 120), (113, 121), (113, 122), (113, 123), (113, 124), (113, 125), (113, 126), (113, 128), (114, 114), (114, 116), (114, 117), (114, 118), (114, 119), (114, 120), (114, 121), (114, 122), (114, 123), (114, 124), (114, 125), (114, 126), (114, 128), (115, 114), (115, 116), (115, 117), (115, 118),
(115, 119), (115, 120), (115, 121), (115, 122), (115, 123), (115, 124), (115, 125), (115, 127), (116, 115), (116, 117), (116, 118), (116, 119), (116, 120), (116, 121), (116, 122), (116, 123), (116, 124), (116, 125), (116, 127), (117, 115), (117, 117), (117, 118), (117, 119), (117, 120), (117, 121), (117, 122), (117, 123), (117, 124), (117, 125), (117, 127), (118, 115), (118, 119), (118, 120), (118, 121), (118, 122), (118, 123), (118, 124), (118, 125), (118, 127), (119, 116), (119, 128), (120, 119), (120, 121), (120, 122), (120, 123), (120, 124), (120, 125), (120, 126), )
coordinates_3C3C3C = ((121, 117),
(122, 116), (122, 119), (123, 116), (123, 118), )
coordinates_000080 = ((76, 123),
(76, 124), (76, 126), (77, 122), (77, 126), (78, 125), (79, 121), (79, 124), (80, 120), (80, 123), (81, 120), (81, 123), (82, 120), (82, 122), (82, 124), (82, 130), (83, 120), (83, 123), (83, 124), (83, 125), (83, 126), (83, 127), (83, 128), (83, 130), (84, 121), (84, 124), (85, 122), (85, 125), (85, 126), (85, 129), (86, 124), (86, 127), (87, 125), (87, 126), )
coordinates_2E8B57 = ((61, 124),
(62, 125), (63, 124), (64, 126), (65, 125), (65, 126), (66, 125), (66, 127), (67, 125), (67, 127), (68, 125), (68, 127), (69, 125), (69, 127), (70, 126), (71, 125), (72, 125), (73, 125), (74, 126), )
coordinates_CC5C5C = ((153, 153),
(154, 150), (154, 153), (155, 148), (155, 153), (156, 146), (156, 149), (156, 153), (157, 153), (158, 152), (159, 148), (159, 151), (160, 147), (160, 149), (161, 146), )
coordinates_CD5C5C = ((82, 147),
(82, 149), (82, 150), (83, 147), (83, 152), (84, 148), (84, 154), (85, 150), (85, 152), (85, 155), (86, 151), (86, 153), (86, 155), (87, 152), (87, 155), (88, 147), (88, 149), (88, 150), (88, 151), (88, 152), (88, 154), (89, 148), (89, 154), (90, 150), (90, 152), (90, 153), (90, 154), )
coordinates_779FB0 = ((109, 147),
(109, 150), (110, 147), (110, 152), (110, 153), (110, 154), (110, 155), (110, 156), (110, 158), (111, 147), (111, 149), (111, 150), (111, 159), (112, 146), (112, 148), (112, 149), (112, 150), (112, 151), (112, 152), (112, 153), (112, 154), (112, 155), (112, 156), (112, 157), (112, 158), (112, 160), (113, 146), (113, 148), (113, 149), (113, 150), (113, 151), (113, 152), (113, 153), (113, 154), (113, 155), (113, 156), (113, 157), (113, 158), (113, 159), (113, 161), (114, 146), (114, 148), (114, 149), (114, 150), (114, 151), (114, 152), (114, 153), (114, 154), (114, 155), (114, 156), (114, 157), (114, 158), (114, 159), (114, 161), (115, 145), (115, 147), (115, 148), (115, 149), (115, 150), (115, 151), (115, 152), (115, 153), (115, 154), (115, 155), (115, 156), (115, 157), (115, 158), (115, 159), (115, 160), (115, 162), (116, 145), (116, 147), (116, 148),
(116, 149), (116, 150), (116, 151), (116, 152), (116, 153), (116, 154), (116, 155), (116, 156), (116, 157), (116, 158), (116, 159), (116, 160), (116, 162), (117, 145), (117, 147), (117, 148), (117, 149), (117, 150), (117, 151), (117, 152), (117, 153), (117, 154), (117, 155), (117, 156), (117, 157), (117, 158), (117, 159), (117, 160), (117, 162), (118, 144), (118, 146), (118, 147), (118, 148), (118, 149), (118, 150), (118, 151), (118, 152), (118, 153), (118, 154), (118, 155), (118, 156), (118, 157), (118, 158), (118, 159), (118, 160), (118, 161), (118, 163), (119, 144), (119, 146), (119, 147), (119, 148), (119, 149), (119, 150), (119, 151), (119, 152), (119, 153), (119, 154), (119, 155), (119, 156), (119, 157), (119, 158), (119, 159), (119, 160), (119, 161), (119, 163), (120, 144), (120, 146), (120, 147), (120, 148), (120, 149), (120, 150), (120, 151),
(120, 152), (120, 153), (120, 154), (120, 155), (120, 156), (120, 157), (120, 158), (120, 159), (120, 160), (120, 161), (120, 163), (121, 144), (121, 146), (121, 147), (121, 148), (121, 149), (121, 150), (121, 151), (121, 152), (121, 153), (121, 154), (121, 155), (121, 156), (121, 157), (121, 158), (121, 159), (121, 160), (121, 161), (121, 163), (122, 145), (122, 147), (122, 148), (122, 149), (122, 150), (122, 151), (122, 152), (122, 153), (122, 154), (122, 155), (122, 156), (122, 157), (122, 158), (122, 159), (122, 160), (122, 161), (122, 163), (123, 145), (123, 147), (123, 148), (123, 149), (123, 150), (123, 151), (123, 152), (123, 153), (123, 154), (123, 155), (123, 156), (123, 157), (123, 158), (123, 159), (123, 160), (123, 162), (124, 144), (124, 146), (124, 147), (124, 148), (124, 149), (124, 150), (124, 151), (124, 152), (124, 153), (124, 154),
(124, 155), (124, 156), (124, 157), (124, 158), (124, 159), (124, 160), (124, 162), (125, 144), (125, 146), (125, 147), (125, 148), (125, 149), (125, 150), (125, 151), (125, 152), (125, 153), (125, 154), (125, 155), (125, 156), (125, 157), (125, 158), (125, 159), (125, 160), (125, 162), (126, 144), (126, 146), (126, 147), (126, 148), (126, 149), (126, 150), (126, 151), (126, 152), (126, 153), (126, 154), (126, 155), (126, 156), (126, 157), (126, 158), (126, 159), (126, 160), (126, 162), (127, 144), (127, 146), (127, 147), (127, 148), (127, 149), (127, 150), (127, 151), (127, 152), (127, 153), (127, 154), (127, 155), (127, 156), (127, 157), (127, 158), (127, 159), (127, 161), (128, 144), (128, 146), (128, 147), (128, 148), (128, 149), (128, 150), (128, 151), (128, 152), (128, 153), (128, 154), (128, 155), (128, 156), (128, 157), (128, 158), (128, 159),
(128, 161), (129, 145), (129, 147), (129, 148), (129, 149), (129, 150), (129, 151), (129, 152), (129, 153), (129, 154), (129, 155), (129, 156), (129, 157), (129, 158), (129, 159), (129, 161), (130, 145), (130, 147), (130, 148), (130, 149), (130, 150), (130, 151), (130, 152), (130, 153), (130, 154), (130, 155), (130, 156), (130, 157), (130, 158), (130, 159), (130, 161), (131, 145), (131, 147), (131, 148), (131, 149), (131, 150), (131, 151), (131, 152), (131, 153), (131, 154), (131, 155), (131, 156), (131, 157), (131, 158), (131, 159), (131, 161), (132, 145), (132, 147), (132, 148), (132, 149), (132, 150), (132, 151), (132, 152), (132, 153), (132, 154), (132, 155), (132, 156), (132, 157), (132, 158), (132, 159), (132, 161), (133, 146), (133, 148), (133, 149), (133, 150), (133, 151), (133, 152), (133, 153), (133, 154), (133, 155), (133, 156), (133, 157),
(133, 160), (134, 146), (134, 148), (134, 149), (134, 150), (134, 151), (134, 152), (134, 153), (134, 154), (134, 155), (134, 156), (134, 159), (135, 146), (135, 148), (135, 149), (135, 150), (135, 151), (135, 152), (135, 153), (135, 154), (135, 155), (135, 157), (136, 147), (136, 150), (136, 151), (136, 152), (136, 153), (136, 156), (137, 148), (137, 155), (138, 150), (138, 153), )
coordinates_010080 = ((159, 119),
(159, 120), (160, 118), (160, 122), (161, 118), (161, 120), (161, 123), (162, 117), (162, 119), (162, 120), (162, 121), (162, 122), (162, 124), (163, 117), (163, 120), (164, 117), (164, 119), (165, 118), (165, 120), (166, 118), (166, 120), (167, 118), (167, 121), (168, 122), (169, 119), (169, 121), (169, 123), )
coordinates_2D8B57 = ((170, 118),
(171, 118), (171, 120), (171, 121), (171, 123), (172, 118), (172, 123), (173, 118), (173, 120), (173, 122), (174, 118), (174, 120), (174, 121), (174, 122), (175, 118), (175, 121), (176, 118), (176, 121), (177, 118), (177, 121), (178, 118), (178, 121), (179, 119), (179, 121), (180, 119), (180, 121), (181, 119), (181, 121), (182, 119), (182, 121), (183, 119), (183, 121), (184, 119), (184, 121), (185, 119), (185, 121), (186, 120), (186, 121), )
coordinates_D1B48C = ((155, 112),
(156, 112), (156, 113), (157, 111), (157, 112), (158, 111), (158, 113), (158, 116), (159, 111), (159, 113), (159, 114), (159, 116), (160, 110), (160, 112), (160, 113), (160, 114), (160, 116), (161, 110), (161, 112), (161, 113), (161, 114), (161, 116), (162, 109), (162, 111), (162, 112), (162, 113), (162, 115), (163, 108), (163, 110), (163, 111), (163, 112), (163, 113), (163, 115), (164, 108), (164, 110), (164, 111), (164, 112), (164, 114), (165, 108), (165, 110), (165, 111), (165, 113), (166, 108), (166, 111), (166, 113), (167, 109), (167, 112), (167, 114), (168, 110), (168, 114), (169, 111), (169, 115), (170, 112), (170, 115), (171, 113), (171, 116), (172, 114), (172, 116), (173, 114), (173, 116), (174, 115), (174, 116), (175, 115), (175, 116), (176, 115), (176, 116), (177, 115), (177, 116), (178, 115), (178, 116), (179, 115), (179, 116), (180, 115),
(180, 116), (181, 115), (181, 116), (182, 115), (183, 116), )
coordinates_FEA600 = ((172, 103),
(173, 102), (173, 103), (174, 101), (174, 102), (174, 107), (174, 108), (175, 100), (175, 102), (175, 106), (175, 109), (176, 100), (176, 102), (176, 106), (176, 109), (177, 100), (177, 102), (177, 106), (177, 109), (178, 100), (178, 102), (178, 105), (178, 106), (178, 107), (178, 109), (179, 99), (179, 101), (179, 102), (179, 103), (179, 106), (179, 107), (179, 108), (179, 110), (180, 94), (180, 100), (180, 101), (180, 102), (180, 103), (180, 105), (180, 106), (180, 107), (180, 108), (180, 110), (181, 92), (181, 96), (181, 99), (181, 100), (181, 101), (181, 102), (181, 103), (181, 111), (182, 93), (182, 98), (182, 99), (182, 100), (182, 101), (182, 102), (182, 105), (182, 106), (182, 107), (182, 108), (182, 109), (182, 113), (183, 96), (183, 97), (183, 103), (183, 111), (183, 114), (184, 98), (184, 100), (184, 102), (184, 114), (185, 112),
(185, 114), (186, 113), (186, 114), )
coordinates_FEA501 = ((58, 110),
(58, 113), (59, 107), (59, 109), (59, 113), (60, 103), (60, 105), (60, 108), (60, 110), (60, 111), (60, 113), (61, 103), (61, 106), (61, 110), (61, 111), (61, 112), (61, 113), (61, 115), (61, 116), (61, 118), (62, 105), (62, 110), (62, 112), (62, 113), (62, 120), (63, 105), (63, 110), (63, 112), (63, 113), (63, 114), (63, 115), (63, 116), (63, 117), (63, 118), (63, 120), (64, 110), (64, 112), (64, 113), (64, 114), (64, 120), (65, 110), (65, 112), (65, 115), (65, 116), (65, 117), (65, 118), (65, 120), (66, 110), (66, 114), (67, 110), (67, 112), (68, 110), (68, 111), )
coordinates_D2B48C = ((63, 122),
(64, 122), (65, 122), (65, 123), (66, 122), (66, 123), (67, 122), (67, 123), (68, 123), (69, 123), (70, 122), (70, 123), (71, 123), (72, 117), (72, 118), (72, 119), (72, 120), (72, 123), (73, 114), (73, 116), (73, 121), (73, 123), (74, 113), (74, 116), (74, 117), (74, 118), (74, 119), (74, 120), (74, 121), (74, 123), (75, 113), (75, 115), (75, 116), (75, 117), (75, 118), (75, 119), (75, 120), (75, 122), (76, 113), (76, 115), (76, 116), (76, 117), (76, 118), (76, 119), (76, 121), (77, 112), (77, 114), (77, 115), (77, 116), (77, 117), (77, 118), (77, 120), (78, 112), (78, 114), (78, 115), (78, 116), (78, 117), (78, 119), (79, 112), (79, 114), (79, 115), (79, 116), (79, 117), (79, 119), (80, 112), (80, 114), (80, 115), (80, 116), (80, 118), (81, 112), (81, 114), (81, 115), (81, 118),
(82, 112), (82, 114), (82, 117), (82, 118), (83, 112), (83, 115), (84, 112), (84, 114), (85, 112), (86, 112), )
|
def countWords(s):
count=1
for i in s:
if i==" ":
count+=1
return count
print(countWords("Hello World This is Rituraj"))
|
def imprime(nota_fiscal):
print(f"Imprimindo nota fiscal {nota_fiscal.cnpj}")
def envia_por_email(nota_fiscal):
print(f"Enviando nota fiscal {nota_fiscal.cnpj} por email")
def salva_no_banco(nota_fiscal):
print(f"Salvando nota fiscal {nota_fiscal.cnpj} no banco")
|
#Write a function that accepts a string and a character as input and returns the
#number of times the character is repeated in the string. Note that
#capitalization does not matter here i.e. a lower case character should be
#treated the same as an upper case character.
def count_character(line, character):
count = 0
for x in line.lower():
if x == character.lower():
count += 1
return count
print(count_character('supernovas are so awesome', 's'))
|
#!/usr/bin/env python
# 平均の求め方
def Average(numList):
return sum(numList) / len(numList)
def main():
numList = [1, 2, 3]
print(Average(numList))
if __name__ == "__main__":
main()
|
"""
Fragments of user mutations
"""
AUTH_PAYLOAD_FRAGMENT = '''
id
token
user {
id
}
'''
USER_FRAGMENT = '''
id
'''
|
def partfast(n):
# base case of the recursion: zero is the sum of the empty tuple
if n == 0:
yield []
return
# modify the partitions of n-1 to form the partitions of n
for p in partfast(n-1):
p.append(1)
yield p
p.pop()
if p and (len(p) < 2 or p[-2] > p[-1]):
p[-1] += 1
yield p
|
mass_list = list(open('d01.in').read().split())
base_fuel = 0
total_fuel = 0
def calculate_fuel(mass):
return int(mass) // 3 - 2
for mass in mass_list:
fuel = calculate_fuel(mass)
base_fuel += fuel
while (fuel >= 0):
total_fuel += fuel
fuel = calculate_fuel(fuel)
print('P1:', base_fuel)
print('P2:', total_fuel)
|
f=open('t.txt','r')
l=f.readlines()
d={}
for i in (l):
k=i.strip()
m = list(k)
if(m[0]=='R'):
d[k] = []
j=k
else:
d[j].append(k)
p=[]
for i in d.keys():
m=d[i]
k=''.join(x for x in m)
d[i]=list(k)
l1 = k.count('G')
l2 = k.count('C')
l = len(d[i])
per = ((l1 + l2) / l) * 100
p.append(per)
m=max(p)
i=p.index(m)
f=list(d.keys())
print(f[i])
print(m)
|
def sign(val):
if val == 0:
return 0
return 1 if val > 0 else -1
def linear_interpolation(val, x0, y0, x1, y1):
return y0 + ((val - x0) * (y1 - y0))/(x1 - x0)
|
# coding=utf8
# Copyright 2018 JDCLOUD.COM
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# NOTE: This class is auto generated by the jdcloud code generator program.
class ListProxycacheUrl(object):
def __init__(self, id=None, uri=None, proto=None, disable=None, matchOp=None, updateTime=None):
"""
:param id: (Optional) 规则id
:param uri: (Optional) 缓存的uri
:param proto: (Optional) 协议
:param disable: (Optional) 0-缓存生效,1-缓存不生效
:param matchOp: (Optional) 匹配模式
:param updateTime: (Optional) 更新时间,s时间戳
"""
self.id = id
self.uri = uri
self.proto = proto
self.disable = disable
self.matchOp = matchOp
self.updateTime = updateTime
|
def bbox_xywh2cxcywh(bbox):
cx = bbox[0] + bbox[2] / 2
cy = bbox[1] + bbox[3] / 2
return (cx, cy, bbox[2], bbox[3])
|
"""Шаблон бинарного поиска"""
def search(sequence, item):
"""Бинарный поиск"""
raise NotImplementedError()
|
class Dog():
def __init__(self, name, age):
self.name = name
self.age = age
def set(self):
print(self.name.title() + '请坐')
class car():
def __init__(self, name, model, year):
self.name = name
self.model = model
self.year = year
def read_name(self):
print(self.name.title())
class Electr_car():
def __init__(self, name, model, year):
super().__init__(name, model, year)
|
A = float(input("Inserire il valore A: ")) # 0.1
B = float(input("Inserire il valore B: ")) # 0.01
C = float(input("Inserire il valore C: ")) # 0.01
D = float(input("Inserire il valore D: ")) # 0.00002
prey_old = int(input("Inserire il valore di prede iniziali: ")) # 1000
pred_old = int(input("Inserire il numero di predatori iniziale: ")) # 20
generations = int(input("Inserisci il numero di generazioni da simulare: "))
print("La popolazione iniziale di prede è", prey_old)
print("La popolazione iniziale di predatori è", pred_old)
for t in range(generations):
prey_new = int(prey_old * (1 + A - B * pred_old))
pred_new = int(pred_old * (1 - C + D * prey_old))
print()
print("Generazione", t + 1)
print("Numero di prede:", prey_new)
print("Numero di predatori:", pred_new)
prey_old = prey_new
pred_old = pred_new
print("Simulazione finita.")
|
class Block(object):
def __init__(self, name) -> None:
super().__init__()
self.__name__ = name
|
"""
# All classes should extend Veggies and override the following methods
def __str__(selt)
"""
class Veggies :
def __str__(self):
assert False, 'This method should be overrided.'
class BlackOlives(Veggies) :
def __str__(self):
return 'Black Olives'
class Garlic(Veggies) :
def __str__(self):
return 'Garlic'
class Mushroom(Veggies) :
def __str__(self):
return 'Mushrooms'
class Onion(Veggies) :
def __str__(self):
return 'Onion'
class RedPepper(Veggies) :
def __str__(self):
return 'Red Pepper'
class Spinach(Veggies) :
def __str__(self):
return 'Spinach'
class Eggplant(Veggies) :
def __str__(self):
return 'Eggplant'
|
print("======================")
print("RADAR ELETRÔNICO!")
print("======================")
limite = 80.0
multa = 7
velocidade = float(input("Qual a sua velocidade: "))
if velocidade <= limite:
print("Boa Tarde, cuidado na estrada, siga viagem!")
else:
valor = (velocidade - limite) * 7
print(f"Você ultrapassou o limite de velocidade e foi multado em {valor:.2f} reais!")
|
def subsets(l):
if not l:
return [[]]
else:
all_subsets = []
for i in range(len(l)):
sub_subsets = subsets(l[:i] + l[i + 1:])
[all_subsets.append(subset) for subset in sub_subsets if subset not in all_subsets]
if l not in all_subsets:
all_subsets.append(l)
all_subsets.sort()
return all_subsets
if __name__ == '__main__':
print(subsets([1, 2, 3]))
|
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
class SizeError( Exception ):
pass
|
"""Package contains objects representing a wordsearch board."""
class Line:
"""Represents a directionless character line on a word search board."""
def __init__(self, index, characters=""):
"""Initialize instance with provided starting characters."""
self.index = index
self.characters = characters
def append(self, letter):
"""Append a single character to the end of the current line."""
if not isinstance(letter, str):
raise TypeError("must provide a string type")
elif len(letter) > 1:
raise ValueError("must provide a single letter")
self.characters += letter
def search(self, word):
"""Abtract search method to be overridden in child classes."""
raise NotImplementedError("this method has not been implemented.")
class HorizontalLine(Line):
"""Representation of a horizontal character line on a word search board."""
def search(self, word):
"""Search for word in the line and return character positions."""
characters = []
try:
position = self.characters.index(word)
for offset in range(len(word)):
characters.append((position + offset, self.index))
except ValueError:
pass
return characters
class VerticalLine(Line):
"""Representation of a vertical character line on a word search board."""
def search(self, word):
"""Search for word in the line and return character positions."""
characters = []
try:
position = self.characters.index(word)
for offset in range(len(word)):
characters.append((self.index, position + offset))
except ValueError:
pass
return characters
class DiagonalEastLine(Line):
"""Representation of diagonal east character line on word search board."""
def search(self, word):
"""Search for word in the line and return character positions."""
characters = []
try:
position = self.characters.index(word)
for offset in range(len(word)):
characters.append(
(self.index+position+offset, position+offset),
)
except ValueError:
pass
return characters
class DiagonalWestLine(Line):
"""Representation of diagonal east character line on word search board."""
def search(self, word):
"""Search for word in the line and return character positions."""
characters = []
try:
position = self.characters.index(word)
for offset in range(len(word)):
characters.append(
(self.index-position-offset, position+offset),
)
except ValueError:
pass
return characters
class Lines:
"""Manager for lines of a similar class."""
def __init__(self, cls):
"""Initialize class instance with the provided Line class type."""
self.cls = cls
self.lines = {}
def get(self, key):
"""Return the desired line instance by key; create if doesn't exist."""
if key not in self.lines:
self.lines[key] = self.cls(key)
return self.lines[key]
class Board:
"""Representation of a wordsearch board."""
def __init__(self, csv):
"""Parse CSV into current board instance."""
if not csv:
raise ValueError("must provide CSV text")
if not isinstance(csv, str):
raise TypeError("CSV argument must be a string")
self.size = 0
self.horizontals = Lines(HorizontalLine)
self.verticals = Lines(VerticalLine)
self.diagonal_easts = Lines(DiagonalEastLine)
self.diagonal_wests = Lines(DiagonalWestLine)
self._parse_input(csv)
def _parse_input(self, csv):
row, column = 0, 0
for line in csv.split("\n"):
column = 0
for char in line.split(","):
if len(char) != 1:
raise ValueError("only single letters allowed per column")
if char.isdigit():
raise ValueError("numbers not allowed in board")
char = char.lower()
self.horizontals.get(row).append(char)
self.verticals.get(column).append(char)
self.diagonal_easts.get(column - row).append(char)
self.diagonal_wests.get(column + row).append(char)
column += 1
row += 1
if row != column:
raise ValueError("provide word search board must be a square")
self.size = row
def search(self, word):
"""Return position of all characters of search term on the board."""
if not isinstance(word, str):
raise TypeError("must provide a string")
if not word or len(word.split(" ")) > 1:
raise ValueError("must provide a single word to search for")
if len(word) > self.size:
return None
word = word.lower()
all_possible_lines = [
*self.horizontals.lines.values(),
*self.verticals.lines.values(),
*self.diagonal_easts.lines.values(),
*self.diagonal_wests.lines.values(),
]
for line in all_possible_lines:
chars = line.search(word)
if chars:
return chars
reversed_chars = line.search(word[::-1])
if reversed_chars:
return reversed_chars[::-1]
return None
|
class Solution:
def numberOfArithmeticSlices(self, nums: List[int]) -> int:
'''
-5 -2 1 4 5 6 7 9 11
<3 = 0
3 -> 1
4 -> 2+1
5 -> 3+2+1
6 -> 4+3+2+1
n -> n(n+1)/2 -n - (n-1)
-> (n^2 - 3n + 2)/2
'''
def getCount(n):
return (n**2 - 3*n + 2)/2
n = len(nums)
if n < 3:
return 0
curr_diff = nums[1]-nums[0]
curr_count = 2
total_count = 0
left = 0
for i in range(2, n):
if nums[i]-nums[i-1] != curr_diff:
total_count += getCount(i - left)
left = i - 1
curr_diff = nums[i]-nums[i-1]
curr_count = 2
total_count += getCount(n - left)
return int(total_count)
|
class HelperError(Exception):
pass
class BaseHelper(object):
def get_current_path(self):
raise HelperError('you have to customized YourHelper.get_current_path')
def get_params(self):
raise HelperError('you have to customized YourHelper.get_params')
def get_body(self):
raise HelperError('you have to customized YourHelper.get_body')
def redirect(self, url):
raise HelperError('you have to customized YourHelper.redirect')
|
class Solution:
def maxSubArray(self, nums: List[int]) -> int:
maxsofar = nums[0]
maxendinghere = nums[0]
for i in range(1, len(nums)):
maxendinghere = max(nums[i], nums[i] + maxendinghere)
maxsofar = max(maxsofar, maxendinghere)
return maxsofar
|
map = [200090710, 200090610]
sm.sendSay("Where would you like to go? \r\n#L0#Victoria Island#l\r\n#L1#Orbis#l")
sm.warp(map[answer], 0)
|
class DependenceNode:
def __init__(self):
self.parents = []
self.children = []
self.inter_parents = []
self.inter_children = []
self.fictitious_parents = []
self.fictitious_children = []
self.ast = None
def add_parent(self, parent):
self.parents.append(parent)
def add_child(self, child):
self.children.append(child)
def add_inter_parent(self, parent):
self.inter_parents.append(parent)
def add_inter_child(self, child):
self.inter_children.append(child)
def add_fictitious_parent(self, parent):
self.fictitious_parents.append(parent)
def add_fictitious_child(self, child):
self.fictitious_children.append(child)
def set_ast(self, ast):
self.ast = ast
def get_parents(self):
return self.parents
def get_children(self):
return self.children
def get_inter_parents(self):
return self.inter_parents
def get_inter_children(self):
return self.inter_children
def get_fictitious_parents(self):
return self.fictitious_parents
def get_fictitious_children(self):
return self.fictitious_children
class InputNode(DependenceNode):
def __init__(self, label):
super().__init__()
self.label = label
def clone(self):
clone = InputNode(self.label)
clone.ast = self.ast
return clone
def __str__(self):
return "IN: " + self.label
class OutputNode(DependenceNode):
def __init__(self, label):
super().__init__()
self.label = label
def clone(self):
clone = OutputNode(self.label)
clone.ast = self.ast
return clone
def __str__(self):
return "OUT: " + self.label
class ConstNode(DependenceNode):
def __init__(self, const_ast):
super().__init__()
self.value = const_ast.value
self.ast = const_ast
def clone(self):
clone = ConstNode(self.ast)
return clone
def __str__(self):
return "CONST: " + self.value
class CondNode(DependenceNode):
def __init__(self, cond_statement):
super().__init__()
self.cond_statement = cond_statement
def clone(self):
clone = CondNode(self.cond_statement)
clone.ast = self.ast
return clone
def __str__(self):
return "COND: " + ", ".join(self.cond_statement.get_cond_dependencies())
class AssignNode(DependenceNode):
def __init__(self, name):
super().__init__()
self.name = name
def clone(self):
clone = AssignNode(self.name)
clone.ast = self.ast
return clone
def __str__(self):
return self.name
class AlwaysNode(DependenceNode):
def __init__(self, sensList):
super().__init__()
self.sensList = sensList
def get_sensList(self):
return self.sensList
def clone(self):
clone = AlwaysNode(self.sensList)
clone.ast = self.ast
return clone
def __str__(self):
return "ALWAYS @(" + " ,".join(self.sensList) + ")"
class CouplingNode(DependenceNode):
def __init__(self, invar, outvars):
super().__init__()
self.invar = invar
self.outvars = outvars
def get_invar(self):
return self.invar
def get_outvars(self):
return self.outvars
def clone(self):
clone = CouplingNode(self.invar, self.outvars)
clone.ast = self.ast
return clone
def __str__(self):
return self.invar + "; " + ", ".join(self.outvars)
class InstanceNode(DependenceNode):
def __init__(self, name):
super().__init__()
self.modulename = name
def get_modulename(self):
return self.modulename
def clone(self):
clone = InstanceNode(self.modulename)
clone.ast = self.ast
return clone
def __str__(self):
return "INSTANCE: " + self.modulename
class ModuleNode(DependenceNode):
def __init__(self, name):
super().__init__()
self.modulename = name
def get_modulename(self):
return self.modulename
def clone(self):
clone = ModuleNode(self.modulename)
clone.ast = self.ast
return clone
def __str__(self):
return "MODULE DEF: " + self.modulename
class ParameterNode(DependenceNode):
def __init__(self, name, ids, consts):
super().__init__()
self.name = name
self.ids = ids
self.consts = consts
def clone(self):
clone = ParameterNode(self.name, self.ids, self.consts)
clone.ast = self.ast
return clone
def __str__(self):
return "PARAMETER: " + self.name +" - " + ", ".join([str(el) for el in self.ids+self.consts])
class FunctionNode(DependenceNode):
def __init__(self, name):
super().__init__()
self.name = name
def clone(self):
clone = FunctionNode(self.name)
clone.ast= self.ast
return clone
def __str__(self):
return "FUNCTION: " + self.name
|
def longest_consec(strarr, k):
output,n = None ,len(strarr)
if n == 0 or k > n or k<=0 :
return ""
for i in range(n-k+1):
aux = ''
for j in range(i,i+k):
aux += strarr[j]
if output == None or len(output) < len(aux):
output = aux
return output
|
#!/usr/bin/env python
# encoding: utf-8
'''
@author: Jason Lee
@license: (C) Copyright @ Jason Lee
@contact: jiansenll@163.com
@file: 56.py
@time: 2019/6/9 21:29
@desc:
'''
class Solution:
def merge(self, intervals: List[List[int]]) -> List[List[int]]:
if not intervals or len(intervals) == 1:
return intervals
coll = sorted(intervals, key=lambda c: c[0])
res = []
start, end = coll[0]
for i, j in coll[1:]:
if i <= end:
end = max(end, j)
else: # 不存在交集
res.append([start, end])
start = i
end = j
# 加入最后一个
res.append([start, end])
return res
|
_CUDA_TOOLKIT_PATH = "CUDA_TOOLKIT_PATH"
_VAI_CUDA_REPO_VERSION = "VAI_CUDA_REPO_VERSION"
_VAI_NEED_CUDA = "VAI_NEED_CUDA"
_DEFAULT_CUDA_TOOLKIT_PATH = "/usr/local/cuda"
# Lookup paths for CUDA / cuDNN libraries, relative to the install directories.
#
# Paths will be tried out in the order listed below. The first successful path
# will be used. For example, when looking for the cudart libraries, the first
# attempt will be lib64/cudart inside the CUDA toolkit.
CUDA_LIB_PATHS = [
"lib64/",
"lib64/stubs/",
"lib/x86_64-linux-gnu/",
"lib/x64/",
"lib/",
"",
]
# Lookup paths for CUDA headers (cuda.h) relative to the CUDA toolkit directory.
CUDA_INCLUDE_PATHS = [
"include/",
"include/cuda/",
]
def get_cpu_value(ctx):
os_name = ctx.os.name.lower()
if os_name.startswith("mac os"):
return "Darwin"
if os_name.find("windows") != -1:
return "Windows"
result = ctx.execute(["uname", "-s"])
return result.stdout.strip()
def _is_windows(ctx):
"""Returns true if the host operating system is windows."""
return get_cpu_value(ctx) == "Windows"
def _lib_name(lib, cpu_value, version = "", static = False):
"""Constructs the platform-specific name of a library.
Args:
lib: The name of the library, such as "cudart"
cpu_value: The name of the host operating system.
version: The version of the library.
static: True the library is static or False if it is a shared object.
Returns:
The platform-specific name of the library.
"""
if cpu_value in ("Linux", "FreeBSD"):
if static:
return "lib%s.a" % lib
else:
if version:
version = ".%s" % version
return "lib%s.so%s" % (lib, version)
if cpu_value == "Windows":
return "%s.lib" % lib
if cpu_value == "Darwin":
if static:
return "lib%s.a" % lib
if version:
version = ".%s" % version
return "lib%s%s.dylib" % (lib, version)
fail("Invalid cpu_value: %s" % cpu_value)
def _tpl(ctx, tpl, substitutions = {}, out = None):
if not out:
out = tpl.replace(":", "/")
ctx.template(
out,
Label("@com_intel_plaidml//vendor/cuda:%s.tpl" % tpl),
substitutions,
)
def _cuda_toolkit_path(ctx):
path = ctx.os.environ.get(_CUDA_TOOLKIT_PATH, _DEFAULT_CUDA_TOOLKIT_PATH)
if not ctx.path(path).exists:
fail("Cannot find CUDA toolkit path.")
return str(ctx.path(path).realpath)
def _get_cuda_config(ctx):
"""Detects and returns information about the CUDA installation on the system.
Args:
ctx: The repository context.
Returns:
A struct containing the following fields:
cuda_toolkit_path: The CUDA toolkit installation directory.
compute_capabilities: A list of the system's CUDA compute capabilities.
cpu_value: The name of the host operating system.
"""
cpu_value = get_cpu_value(ctx)
cuda_toolkit_path = _cuda_toolkit_path(ctx)
return struct(
cuda_toolkit_path = cuda_toolkit_path,
# compute_capabilities = _compute_capabilities(ctx),
cpu_value = cpu_value,
)
def _find_cuda_include_path(ctx, cuda_config):
"""Returns the path to the directory containing cuda.h
Args:
ctx: The repository context.
cuda_config: The CUDA config as returned by _get_cuda_config
Returns:
The path of the directory containing the CUDA headers.
"""
cuda_toolkit_path = cuda_config.cuda_toolkit_path
for relative_path in CUDA_INCLUDE_PATHS:
if ctx.path("%s/%scuda.h" % (cuda_toolkit_path, relative_path)).exists:
return ("%s/%s" % (cuda_toolkit_path, relative_path))[:-1]
fail("Cannot find cuda.h under %s" % cuda_toolkit_path)
def _create_dummy_repository(ctx):
cpu_value = get_cpu_value(ctx)
_tpl(ctx, "build_defs.bzl", {
"%{cuda_is_configured}": "False",
})
_tpl(ctx, "BUILD", {
"%{cuda_driver_lib}": _lib_name("cuda", cpu_value),
"%{nvrtc_lib}": _lib_name("nvrtc", cpu_value),
"%{nvrtc_builtins_lib}": _lib_name("nvrtc-builtins", cpu_value),
"%{cuda_include_genrules}": "",
"%{cuda_headers}": "",
})
ctx.file("include/cuda.h", "")
ctx.file("lib/%s" % _lib_name("cuda", cpu_value))
def _find_cuda_lib(lib, ctx, cpu_value, basedir, version = "", static = False):
"""Finds the given CUDA or cuDNN library on the system.
Args:
lib: The name of the library, such as "cudart"
ctx: The repository context.
cpu_value: The name of the host operating system.
basedir: The install directory of CUDA or cuDNN.
version: The version of the library.
static: True if static library, False if shared object.
Returns:
Returns a struct with the following fields:
file_name: The basename of the library found on the system.
path: The full path to the library.
"""
file_name = _lib_name(lib, cpu_value, version, static)
for relative_path in CUDA_LIB_PATHS:
path = ctx.path("%s/%s%s" % (basedir, relative_path, file_name))
if path.exists:
return struct(file_name = file_name, path = str(path.realpath))
fail("Cannot find cuda library %s" % file_name)
def _find_libs(ctx, cuda_config):
"""Returns the CUDA and cuDNN libraries on the system.
Args:
ctx: The repository context.
cuda_config: The CUDA config as returned by _get_cuda_config
Returns:
Map of library names to structs of filename and path.
"""
cpu_value = cuda_config.cpu_value
return {
"cuda": _find_cuda_lib("cuda", ctx, cpu_value, cuda_config.cuda_toolkit_path),
"nvrtc": _find_cuda_lib("nvrtc", ctx, cpu_value, cuda_config.cuda_toolkit_path),
"nvrtc_builtins": _find_cuda_lib("nvrtc-builtins", ctx, cpu_value, cuda_config.cuda_toolkit_path),
}
def _execute(ctx, cmdline, error_msg = None, error_details = None, empty_stdout_fine = False):
"""Executes an arbitrary shell command.
Args:
ctx: The repository context.
cmdline: list of strings, the command to execute
error_msg: string, a summary of the error if the command fails
error_details: string, details about the error or steps to fix it
empty_stdout_fine: bool, if True, an empty stdout result is fine, otherwise
it's an error
Return:
the result of ctx.execute(cmdline)
"""
result = ctx.execute(cmdline)
if result.stderr or not (empty_stdout_fine or result.stdout):
fail(
"\n".join([
error_msg.strip() if error_msg else "Repository command failed",
result.stderr.strip(),
error_details if error_details else "",
]),
)
return result
def _read_dir(ctx, src_dir):
"""Returns a string with all files in a directory.
Finds all files inside a directory, traversing subfolders and following
symlinks. The returned string contains the full path of all files
separated by line breaks.
"""
if _is_windows(ctx):
src_dir = src_dir.replace("/", "\\")
find_result = _execute(
ctx,
["cmd.exe", "/c", "dir", src_dir, "/b", "/s", "/a-d"],
empty_stdout_fine = True,
)
# src_files will be used in genrule.outs where the paths must
# use forward slashes.
result = find_result.stdout.replace("\\", "/")
else:
find_result = _execute(
ctx,
["find", src_dir, "-follow", "-type", "f"],
empty_stdout_fine = True,
)
result = find_result.stdout
return result
def _norm_path(path):
"""Returns a path with '/' and remove the trailing slash."""
path = path.replace("\\", "/")
if path[-1] == "/":
path = path[:-1]
return path
def symlink_genrule_for_dir(ctx, src_dir, dest_dir, genrule_name, src_files = [], dest_files = []):
"""Returns a genrule to symlink(or copy if on Windows) a set of files.
If src_dir is passed, files will be read from the given directory; otherwise
we assume files are in src_files and dest_files
"""
if src_dir != None:
src_dir = _norm_path(src_dir)
dest_dir = _norm_path(dest_dir)
files = "\n".join(sorted(_read_dir(ctx, src_dir).splitlines()))
# Create a list with the src_dir stripped to use for outputs.
dest_files = files.replace(src_dir, "").splitlines()
src_files = files.splitlines()
command = []
# We clear folders that might have been generated previously to avoid undesired inclusions
if genrule_name == "cuda-include":
command.append('if [ -d "$(@D)/cuda/include" ]; then rm -rf $(@D)/cuda/include; fi')
elif genrule_name == "cuda-lib":
command.append('if [ -d "$(@D)/cuda/lib" ]; then rm -rf $(@D)/cuda/lib; fi')
outs = []
for i in range(len(dest_files)):
if dest_files[i] != "":
# If we have only one file to link we do not want to use the dest_dir, as
# $(@D) will include the full path to the file.
dest = "$(@D)/" + dest_dir + dest_files[i] if len(dest_files) != 1 else "$(@D)/" + dest_files[i]
command.append("mkdir -p $$(dirname {})".format(dest))
command.append('cp -f "{}" "{}"'.format(src_files[i], dest))
outs.append(' "{}{}",'.format(dest_dir, dest_files[i]))
return _genrule(src_dir, genrule_name, command, outs)
def _genrule(src_dir, genrule_name, command, outs):
"""Returns a string with a genrule.
Genrule executes the given command and produces the given outputs.
"""
return "\n".join([
"genrule(",
' name = "{}",'.format(genrule_name),
" outs = [",
] + outs + [
" ],",
' cmd = """',
] + command + [
' """,',
")",
])
def _create_cuda_repository(ctx):
cpu_value = get_cpu_value(ctx)
_tpl(ctx, "build_defs.bzl", {
"%{cuda_is_configured}": "True",
})
cuda_config = _get_cuda_config(ctx)
cuda_include_path = _find_cuda_include_path(ctx, cuda_config)
cuda_libs = _find_libs(ctx, cuda_config)
cuda_lib_src = []
cuda_lib_dest = []
for lib in cuda_libs.values():
cuda_lib_src.append(lib.path)
cuda_lib_dest.append("cuda/lib/" + lib.file_name)
genrules = [
symlink_genrule_for_dir(ctx, cuda_include_path, "cuda/include", "cuda-include"),
symlink_genrule_for_dir(ctx, None, "", "cuda-lib", cuda_lib_src, cuda_lib_dest),
]
_tpl(ctx, "BUILD", {
"%{cuda_driver_lib}": cuda_libs["cuda"].file_name,
"%{nvrtc_lib}": cuda_libs["nvrtc"].file_name,
"%{nvrtc_builtins_lib}": cuda_libs["nvrtc_builtins"].file_name,
"%{cuda_include_genrules}": "\n".join(genrules),
"%{cuda_headers}": '":cuda-include",',
})
def _configure_cuda_impl(ctx):
enable_cuda = ctx.os.environ.get(_VAI_NEED_CUDA, "0").strip()
if enable_cuda == "1":
_create_cuda_repository(ctx)
else:
_create_dummy_repository(ctx)
configure_cuda = repository_rule(
environ = [
_CUDA_TOOLKIT_PATH,
_VAI_CUDA_REPO_VERSION,
_VAI_NEED_CUDA,
],
implementation = _configure_cuda_impl,
)
|
f = open("demo.txt", "r")#read file
print(f.read())
c=open("demosfile.txt","r")
print(c.read())
w= open("demo.txt", "a") #update file with additional data
w.write("Now the file has one more line!")
ow = open("demo.txt", "w") #delete entire content and add new content
ow.write("Woops! I have deleted the content!")
new= open("demosfile.txt","w") #create new file and add content
new.write("a new file is created with python program and content is added")
|
#!usr/bin/python
# -*- coding:utf8 -*-
class people:
# 定义基本属性
job = "gopher"
def __init__(self, name, age, weight):
self.name = name
self.age = age
# 注意__xx是私有变量,self._weight外部是可以直接访问到的
self.__weight = weight # 私有变量,翻译成了self._A__name = "python"
def speak(self):
print("%s 说: 我 %d 岁. " %(self.name, self.age))
class student(people):
grade = '99'
def __init__(self, name, age, weight, grade):
# 调用父类的构造函数 子类中需要父类的构造方法就需要显示地调用父类的构造方法,或者不重写父类的构造方法
people.__init__(self, name, age, weight)
self.grade = grade
# override
def speak(self):
print("{}说: 我{}岁了.我在读{}年级".format(self.name, self.age, self.grade))
# 加上下面报错 AttributeError: 'student' object has no attribute '_student__weight'
# print(self.__weight)
# 私有方法
def __print(self):
print("hello world")
s = student("clarece", "25", "140", "9")
s.speak()
# 当实例属性和类属性重名时,实例属性优先级高,将会屏蔽对类属性的访问
print(student.grade, s.grade) # 分别是类变量和实例的成员变量
print(s._people__weight) #通过这种方式,在外面也能够访问“私有”变量;这一点在调试中是比较有用的
print(student.job)
|
"""
Home of all the miscellaneous BrainPywer utilities that don't deserve their own files
"""
def thaw(snowflake):
"""
Tiny function to return the unix timestamp of a snowflake
:param snowflake: a discord snowflake (It's unique, just like you! ha.)
:type snowflake: int
:return: unix timestamp of the message
:rtype: int
"""
return ((snowflake >> 22)+1420070400000)/1000
|
"""
Programa 054
Área de estudos.
data 24.11.2020 (Indefinida) Hs
@Autor: Abraão A. Silva
"""
# Gerando valores impares dos parêmetros de "range()".
# Opção 1
for num in range(1, 151):
if num % 2 != 0:
print(num, end=' ')
# Opção 2
for num in range(1, 151, 2):
print(num, end=' ')
|
"""
Problem Description:
In india there is a puzzle"5 characters my name, reverse- forward is the same." You will be presented with a 5 character String, you have to tell whether it satisfy above puzzle, if yes output "Yes" else "No"
Input:
Input is String S of 5 characters.
Output:
Print "Yes" if the String S satisfies above constraints, else "No".
Constraints:
String length = 5
Sample Input:
level
Sample Output:
Yes
"""
a = input()
print("Yes") if a == a[::-1] else print("No")
|
# Banker's Algorithm
n = 5 # no. of processes / rows
m = 4 # no. of resources / columns
# Maximum matrix - denotes maximum demand of each process
maxi = [[0, 0, 1, 2],
[1, 7, 5, 0],
[2, 3, 5, 6],
[0, 6, 5, 2],
[0, 6, 5, 6]]
# Allocation matrix - denotes no. of resources allocated to processes
alloc = [[0, 0, 1, 2],
[1, 0, 0, 0],
[1, 3, 5, 4],
[0, 6, 3, 2],
[0, 0, 1, 4]]
# Available matrix - no. of available resources of each type
avail = [1, 5, 2, 0]
f = [0]*n
ans = [0]*n
ind = 0
need = [[ 0 for i in range(m)]for i in range(n)]
for i in range(n):
for j in range(m):
need[i][j] = maxi[i][j] - alloc[i][j]
y = 0
for k in range(5):
for i in range(n):
if (f[i] == 0):
flag = 0
for j in range(m):
if (need[i][j] > avail[j]):
flag = 1
break
if (flag == 0):
ans[ind] = i
ind += 1
for y in range(m):
avail[y] += alloc[i][y]
f[i] = 1
print("Following is the SAFE Sequence")
for i in range(n - 1):
print(" P", ans[i], " ->", sep="", end="")
print(" P", ans[n - 1], sep="")
|
class dotGuideline_t(object):
# no doc
Curve = None
Id = None
Spacing = None
|
# draw some simple shapes
# hint! The order in which you draw is important
# change x and y to move him around
x = width/2
y = 25
w = 23 # make him bigger or smaller
h = w # distort by changing the h seperatly
bmi = 1 # body mass index
# a line takes 4 values the starting point and the end point
line(x - w, y + h, x +w, y+h)
# a ellipse always takes 4 values as parameter
ellipse(x, y, w, h)
# a point just two
point(x, y) # look he has a nose
# a rectangle also takes 4 values like the ellipse
# but draws from its upper left corner
rect(x-bmi/2, y + h, bmi, h)
# you can also draw free forms by using vertecies
noFill()
beginShape()
vertex(x - w, y + h*3)
vertex(x - w, y + h*2)
vertex(x + w, y + h*2)
vertex(x + w, y + h*3)
endShape()
|
class ClientError(Exception):
pass
class ProtocolError(ClientError):
""" Error communicating with the OpenVPN server """
pass
class InvalidPacketError(ProtocolError):
""" Packet that doesn't make any sense and cannot be read correctly. """
pass
class InvalidHMACError(InvalidPacketError):
pass
class ProtocolLogicError(ProtocolError):
""" Unsupported stuff, unexpected packets, ...
Things that are readable but not supported by this implementation.
"""
pass
class AuthFailed(ClientError):
pass
class ConfigError(ClientError):
pass
class Channel:
def __init__(self):
self.queue = []
def push_packet(self, packet):
self.queue.append(packet)
def _send(self, packet):
self.c._send(packet)
|
AdminApp.install('/tmp/installers/war_app/JspDemo.war', '[ -nopreCompileJSPs -distributeApp -nouseMetaDataFromBinary -nodeployejb -appname JspDemo -createMBeansForResources -noreloadEnabled -nodeployws -validateinstall warn -noprocessEmbeddedConfig -filepermission .*\.dll=755#.*\.so=755#.*\.a=755#.*\.sl=755 -noallowDispatchRemoteInclude -noallowServiceRemoteInclude -asyncRequestDispatchType DISABLED -nouseAutoLink -noenableClientModule -clientMode isolated -novalidateSchema -contextroot /JspDemo -MapModulesToServers [[ JspDemo JspDemo.war,WEB-INF/web.xml WebSphere:cell=mywasNode01Cell,node=mywasNode01,server=server1 ]] -MapWebModToVH [[ JspDemo JspDemo.war,WEB-INF/web.xml default_host ]] -CtxRootForWebMod [[ JspDemo JspDemo.war,WEB-INF/web.xml /JspDemo ]]]' )
AdminConfig.save()
AdminControl.invoke('WebSphere:name=ApplicationManager,process=server1,platform=proxy,node=mywasNode01,version=8.5.5.0,type=ApplicationManager,mbeanIdentifier=ApplicationManager,cell=mywasNode01Cell,spec=1.0', 'startApplication', '[JspDemo]', '[java.lang.String]')
|
class Queue(object):
def __init__(self,vals,n=10):
self.queue = [None for x in range(n)]
self.head = -1
self.tail = -1
for val in vals:
self.add(val)
def add(self,val):
if (self.tail+1) % len(self.queue) == self.head:
print("Queue full")
return False
elif self.head == -1 and self.tail == -1:
self.queue[0] = val
self.head = 0
self.tail = 0
elif self.tail == len(self.queue) -1 and self.head != 0:
print("Wrapping around")
self.queue[0] = val
self.tail = 0
else:
self.queue[self.tail+1] = val
self.tail += 1
def pop(self):
last = False
if self.head == -1:
return False
elif self.head == self.tail:
last = True
tmp = self.queue[self.head]
self.queue[self.head] = None
if last:
self.head = -1
self.tail = -1
else:
self.head = (self.head + 1) % len(self.queue)
return tmp
def __repr__(self):
return "{} Head: {}, Tail: {}".format(self.queue,self.head,self.tail)
if __name__ == "__main__":
queue = Queue(["a","b","c"],4)
print(queue)
queue.add("d")
print(queue)
queue.pop()
print(queue)
queue.add("e")
|
"""
DAY 41 : Find first set bit.
https://www.geeksforgeeks.org/position-of-rightmost-set-bit/
QUESTION : Given an integer an N. The task is to return the position of first set bit found from the right
side in the binary representation of the number.
Note: If there is no set bit in the integer N, then return 0 from the function.
Expected Time Complexity: O(log N).
Expected Auxiliary Space: O(1).
Constraints:
0 <= N <= 10^8
"""
def getFirstSetBit(n):
pos = 1
while n>0:
if n&1 == 1:
return pos
n = n>>1
pos+=1
return 0
print(getFirstSetBit(12))
|
# Split into train and test data for GAN
def build_dataset(X, nx, ny, n_test = 0):
m = X.shape[0]
print("Number of images: " + str(m) )
X = X.T
Y = np.zeros((m,))
# Random permutation of samples
p = np.random.permutation(m)
X = X[:,p]
Y = Y[p]
# Reshape X and crop to 96x96 pixels
X_new = np.zeros((m,nx,ny))
for i in range(m):
Xtemp = np.reshape(X[:,i],(101,101))
X_new[i,:,:] = Xtemp[2:98,2:98]
X_train = X_new[0:m-n_test,:,:]
Y_train = Y[0:m-n_test]
X_test = X_new[m-n_test:m,:,:]
Y_test = Y[m-n_test:m]
print("X_train shape: " + str(X_train.shape))
print("Y_train shape: " + str(Y_train.shape))
return X_train, Y_train, X_test, Y_test
|
#
# Solution to Project Euler Problem 1
# by Lucas Chen
#
# Answer: 233168
#
NUM = 1000
# Compute sum of the naturals that are a multiple of 3 or 5 and less than [NUM]
def compute():
return sum(i for i in range(1, NUM) if i % 3 == 0 or i % 5 == 0)
if __name__ == "__main__":
print(compute())
|
n=int(input("enter a number "))
backup=n
num=0
while(n>0):
x=n%10
n=n//10
x=x**3
num+=x
if(num==backup):
print(num,"is a armstrong number")
else:
print(backup,"is not a armstrong number")
|
# Copyright (c) 2019-present, Facebook, Inc.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.
#
def f_gold ( arr , n , k ) :
for i in range ( 0 , k ) :
x = arr [ 0 ]
for j in range ( 0 , n - 1 ) :
arr [ j ] = arr [ j + 1 ]
arr [ n - 1 ] = x
#TOFILL
if __name__ == '__main__':
param = [
([75],0,0,),
([-58, -60, -38, 48, -2, 32, -48, -46, 90, -54, -18, 28, 72, 86, 0, -2, -74, 12, -58, 90, -30, 10, -88, 2, -14, 82, -82, -46, 2, -74],27,17,),
([0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1],7,7,),
([45, 51, 26, 36, 10, 62, 62, 56, 61, 67, 86, 97, 31, 93, 32, 1, 14, 25, 24, 30, 1, 44, 7, 98, 56, 68, 53, 59, 30, 90, 79, 22],23,24,),
([-88, -72, -64, -46, -40, -16, -8, 0, 22, 34, 44],6,6,),
([0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0],23,30,),
([8, 17, 20, 23, 31, 32, 37, 37, 44, 45, 48, 64, 64, 67, 69, 71, 75, 77, 78, 81, 83, 87, 89, 92, 94],21,20,),
([-8, -88, -68, 48, 8, 50, 30, -88, 74, -16, 6, 74, 36, 32, 22, 96, -2, 70, 40, -46, 98, 34, 2, 94],23,13,),
([0, 0, 0, 0, 1, 1, 1, 1, 1],5,8,),
([80, 14, 35, 25, 60, 86, 45, 95, 32, 29, 94, 6, 63, 66, 38],9,7,)
]
filled_function_param = [
([75],0,0,),
([-58, -60, -38, 48, -2, 32, -48, -46, 90, -54, -18, 28, 72, 86, 0, -2, -74, 12, -58, 90, -30, 10, -88, 2, -14, 82, -82, -46, 2, -74],27,17,),
([0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1],7,7,),
([45, 51, 26, 36, 10, 62, 62, 56, 61, 67, 86, 97, 31, 93, 32, 1, 14, 25, 24, 30, 1, 44, 7, 98, 56, 68, 53, 59, 30, 90, 79, 22],23,24,),
([-88, -72, -64, -46, -40, -16, -8, 0, 22, 34, 44],6,6,),
([0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0],23,30,),
([8, 17, 20, 23, 31, 32, 37, 37, 44, 45, 48, 64, 64, 67, 69, 71, 75, 77, 78, 81, 83, 87, 89, 92, 94],21,20,),
([-8, -88, -68, 48, 8, 50, 30, -88, 74, -16, 6, 74, 36, 32, 22, 96, -2, 70, 40, -46, 98, 34, 2, 94],23,13,),
([0, 0, 0, 0, 1, 1, 1, 1, 1],5,8,),
([80, 14, 35, 25, 60, 86, 45, 95, 32, 29, 94, 6, 63, 66, 38],9,7,)
]
n_success = 0
for i, parameters_set in enumerate(param):
f_filled(*(filled_function_param[i]))
f_gold(*parameters_set)
if parameters_set == filled_function_param[i]:
n_success+=1
print("#Results: %i, %i" % (n_success, len(param)))
|
#
# PySNMP MIB module CISCO-DOT11-HT-PHY-CAPABILITY (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/CISCO-DOT11-HT-PHY-CAPABILITY
# Produced by pysmi-0.3.4 at Mon Apr 29 17:38:23 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)
#
ObjectIdentifier, OctetString, Integer = mibBuilder.importSymbols("ASN1", "ObjectIdentifier", "OctetString", "Integer")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ValueRangeConstraint, ConstraintsIntersection, SingleValueConstraint, ConstraintsUnion, ValueSizeConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ValueRangeConstraint", "ConstraintsIntersection", "SingleValueConstraint", "ConstraintsUnion", "ValueSizeConstraint")
ciscoAgentCapability, = mibBuilder.importSymbols("CISCO-SMI", "ciscoAgentCapability")
NotificationGroup, AgentCapabilities, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "AgentCapabilities", "ModuleCompliance")
MibScalar, MibTable, MibTableRow, MibTableColumn, iso, TimeTicks, Counter32, Unsigned32, MibIdentifier, Integer32, IpAddress, Counter64, Bits, NotificationType, ModuleIdentity, ObjectIdentity, Gauge32 = mibBuilder.importSymbols("SNMPv2-SMI", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "iso", "TimeTicks", "Counter32", "Unsigned32", "MibIdentifier", "Integer32", "IpAddress", "Counter64", "Bits", "NotificationType", "ModuleIdentity", "ObjectIdentity", "Gauge32")
DisplayString, TextualConvention, TruthValue = mibBuilder.importSymbols("SNMPv2-TC", "DisplayString", "TextualConvention", "TruthValue")
cDot11HtPhyCapability = ModuleIdentity((1, 3, 6, 1, 4, 1, 9, 7, 551))
cDot11HtPhyCapability.setRevisions(('2007-08-22 00:00',))
if mibBuilder.loadTexts: cDot11HtPhyCapability.setLastUpdated('200708220000Z')
if mibBuilder.loadTexts: cDot11HtPhyCapability.setOrganization('Cisco Systems, Inc.')
cDot11HtPhyCapabilityV12R0410BJA = AgentCapabilities((1, 3, 6, 1, 4, 1, 9, 7, 551, 1))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cDot11HtPhyCapabilityV12R0410BJA = cDot11HtPhyCapabilityV12R0410BJA.setProductRelease('Cisco IOS 12.4(10b)JA for the AP1250 802.11 \n Access Points')
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cDot11HtPhyCapabilityV12R0410BJA = cDot11HtPhyCapabilityV12R0410BJA.setStatus('current')
mibBuilder.exportSymbols("CISCO-DOT11-HT-PHY-CAPABILITY", cDot11HtPhyCapabilityV12R0410BJA=cDot11HtPhyCapabilityV12R0410BJA, PYSNMP_MODULE_ID=cDot11HtPhyCapability, cDot11HtPhyCapability=cDot11HtPhyCapability)
|
#!/usr/bin/env python
class Solution:
def wordBreak(self, s, wordDict):
if len(s) == 0: return True
ret = False
for w in wordDict:
if s.startswith(w):
ret = ret or self.wordBreak(s[len(w):], wordDict)
return ret
s, wordDict = 'leetcode', ['leet', 'code']
s, wordDict = 'applepenapple', ['apple', 'pen']
s, wordDict = 'catsandog', ['cats', 'dog', 'sand', 'and', 'cat']
sol = Solution()
print(sol.wordBreak(s, wordDict))
|
exp = []
e = str(input('Digite a expressão: '))
for s in e:
if s == '(':
exp.append('(')
elif s == ')':
if len(exp) > 0:
exp.pop()
else:
exp.append(')')
break
print('Sua expressão é valida' if len(exp) == 0 else 'Sua expressão é inválida')
|
customer_basket_cost = 34
customer_basket_weight = 44
shipping_cost = customer_basket_weight * 1.2
#Write if statement here to calculate the total cost
if customer_basket_weight >= 100:
coste_cesta = customer_basket_cost
print("Total: " + str(coste_cesta) + " euros")
else:
coste_cesta = customer_basket_cost + shipping_cost
print("Total: " + str(coste_cesta) + " euros")
|
def test():
# Here we can either check objects created in the solution code, or the
# string value of the solution, available as __solution__. A helper for
# printing formatted messages is available as __msg__. See the testTemplate
# in the meta.json for details.
# If an assertion fails, the message will be displayed
assert not cat_cols is None, "Your answer for cat_cols does not exist. Have you assigned the list of labels for categorical columns to the correct variable name?"
assert type(cat_cols) == list, "cat_cols does not appear to be of type list. Can you store all the labels of the categorical columns into a list called cat_cols?"
assert set(cat_cols) == set(['species', 'island', 'sex']), "Make sure you only include the categorical columns in cat_cols. Hint: there are 3 categorical columns in the dataframe."
assert cat_cols == ['species', 'island', 'sex'], "You're close. Please make sure that the categorical columns are ordered in the same order they appear in the dataframe."
assert not categorical_plots is None, "Your answer for categorical_plots does not exist. Have you assigned the chart object to the correct variable name?"
assert type(categorical_plots) == alt.vegalite.v4.api.RepeatChart, "Your answer is not an Altair RepeatChart object. Check to make sure that you have assigned an alt.Chart object to categorical_plots and that you are repeating by columns in cat_cols."
assert categorical_plots.spec.mark == 'circle', "Make sure you are using the 'mark_circle' to generate the plots."
assert (
([categorical_plots.spec.encoding.x.shorthand,
categorical_plots.spec.encoding.y.shorthand] ==
[alt.RepeatRef(repeat = 'row'),
alt.RepeatRef(repeat = 'column')]) or
([categorical_plots.spec.encoding.x.shorthand,
categorical_plots.spec.encoding.y.shorthand] ==
[alt.RepeatRef(repeat = 'column'),
alt.RepeatRef(repeat = 'row')])
), "Make sure you specify that the chart set-up is repeated for different rows & columns as the x-axis and y-axis encodings. Hint: use alt.repeat() with row and column arguments."
assert categorical_plots.spec.encoding.x.type == "nominal", "Make sure you let Altair know that alt.repeat() on the x-axis encoding is a nominal type. Altair can't infer the type since alt.repeat() is not a column in the dataframe."
assert categorical_plots.spec.encoding.y.type == "nominal", "Make sure you let Altair know that alt.repeat() on the y-axis encoding is a nominal type. Altair can't infer the type since alt.repeat() is not a column in the dataframe."
assert categorical_plots.spec.encoding.color != alt.utils.schemapi.Undefined and (
categorical_plots.spec.encoding.color.field in {'count()', 'count():quantitative', 'count():Q'} or
categorical_plots.spec.encoding.color.shorthand in {'count()', 'count():quantitative', 'count():Q'}
), "Make sure you are using 'count()' as the color encoding."
assert categorical_plots.spec.encoding.color.title is None, "Make sure you specify that no title should be assigned for color encoding. Hint: use None"
assert categorical_plots.spec.encoding.size != alt.utils.schemapi.Undefined and (
categorical_plots.spec.encoding.size.field in {'count()', 'count():quantitative', 'count():Q'} or
categorical_plots.spec.encoding.size.shorthand in {'count()', 'count():quantitative', 'count():Q'}
), "Make sure you are using 'count()' as the size encoding."
assert categorical_plots.spec.encoding.size.title is None, "Make sure you specify that no title should be assigned for size encoding. Hint: use None"
assert categorical_plots.resolve != alt.utils.schemapi.Undefined and categorical_plots.resolve.scale != alt.utils.schemapi.Undefined and (
categorical_plots.resolve.scale.color == "independent" and
categorical_plots.resolve.scale.size == "independent"
), "Make sure to give the size and colour channels independent scales. Hint: use resolve_scale"
__msg__.good("You're correct, well done!")
|
n, q = map(int, input().split())
graph = [[] for _ in range(n)]
for i in range(n - 1):
a, b = map(int, input().split())
graph[a - 1].append(b - 1)
graph[b - 1].append(a - 1)
group = [[], []]
town_color = [-1] * n
tmp = [[0, -1, 0]]
while tmp:
v, past, color = tmp.pop()
town_color[v] = color
group[color].append(v + 1)
for i in graph[v]:
if i == past: continue
tmp.append([i, v, color ^ 1])
# print(group[0])
# print(group[1])
# print(town_color)
for i in range(q):
c, d = map(int, input().split())
if town_color[c - 1] == town_color[d - 1]:
print("Town")
else:
print("Road")
|
def main():
grid = open("data.txt").readlines()
for i in range(0, len(grid)):
grid[i] = grid[i][:-1]
x_width = len(grid[i])
y_length = len(grid)
ctr = 0
y_pos = 0
x_pos = 0
product = 1
for i in [[1,1], [3,1], [5,1], [7,1], [1,2]]:
while y_pos < y_length:
if grid[y_pos][x_pos % x_width] == '#':
ctr += 1
x_pos += i[0]
y_pos += i[1]
print(ctr)
product *= ctr
x_pos=0
y_pos=0
ctr=0
print(product)
main()
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.