content
stringlengths
7
1.05M
def Dict1(): return {'key1': 'value1'} def Dict2(): return {'key2': 'value1'} # print(Dict1().update(Dict2())) # None d = Dict1() d.update(Dict2()) print(d)
expected_output = { 'confd-status': 'Started', 'processes': { 'nesd': { 'state': 'Active', 'status': 'Running' }, 'syncfd': { 'state': 'Active', 'status': 'Running' }, 'ncsshd': { 'state': 'Not Applicable', 'status': 'Running' }, 'dmiauthd': { 's...
## Izveido programmu, kas nosaka vai lietotāja ievadītais skaitlis ir pāra vai nepāra. skaitlis = int(input("Ievadi skaitli:")) if skaitlis % 2 == 0: print(skaitlis," = pāra skaitlis") else: print(skaitlis, " = nepāra skaitlis")
# List Cycle # https://www.interviewbit.com/problems/list-cycle/ # # Given a linked list, return the node where the cycle begins. If there is no cycle, return null. # # Try solving it using constant additional space. # # Example : # # Input : # # ______ # | | # \/...
step( """ alter table image add column title text, add column description text """, """ alter table image drop column description, drop column title """ )
number = 73167176531330624919225119674426574742355349194934969835203127745063262395783180169848018694788518438586156078911294949545950173795833195285320880551112540698747158523863050715693290963295227443043557668966489504452445231617318564030987111217223831136222989342338030813533627661428280644448664523874930358907296...
__all__ = ( 'UIDValueError', 'ModelFieldError', 'ModelValidationError', 'EmailValidationError', 'PhoneValidationError', 'ForcedBalanceError', 'KeyCloakMigrationError' ) class UIDValueError(ValueError): pass class ModelFieldError(Exception): pass class ModelValidationError(Excep...
# # PySNMP MIB module NCRBSC-OPT-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/NCRBSC-OPT-MIB # Produced by pysmi-0.3.4 at Mon Apr 29 20:08:02 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (default, Mar 27 2...
def main(name): print(f'Hey {name}') if __name__ == '__main__': name = 'Astarag' main(name)
def gather_writable_check_list(hook, check_list, **kwargs): pass def before_project_updated(hook, project_uploader, **kwargs): pass def after_project_updated(hook, project_uploader, **kwargs): pass def before_resource_group_updated(hook, resource_group_uploader, **kwargs): pass def after_resource_gr...
""" 'Constants' in the Redmine schema. It is possible, even probable, that you will need to customize this based on your installation. """ REDMINE_CONSTS = { 'TRACKER': { 'BUG': 1, 'FEATURE': 2, 'SUPPORT': 3 }, 'STATUS': { 'NEW': 1, 'IN_PROGRESS': 2, 'RESOLVED': 3,...
#! /usr/bin/env python3 x = 2.21 print(str(x), "Gigowatts !!!", str(x), "Gigowatts !! Nom de Zeus ! Marty !") print("%s Gigowatts !!! %s Gigowatts !! Nom de Zeus ! Marty !" %(x, x)) print("{} Gigowatts !!! {} Gigowatts !! Nom de Zeus ! Marty !".format(x, x))
class Solution: def combinationSum(self, candidates, target: int): res = [] for i in candidates: if i == target: res.append([i]) continue if i > target: continue ext = self.combinationSum(candidates, target - i) ...
# Largest Palindrome Product # A palindromic number reads the same both ways. The largest palindrome made from the product of two 2-digit numbers is 9009 = 91 × 99. # Find the largest palindrome made from the product of two 3-digit numbers. def main(): i = 100 j = 100 ans = 0 while (i <= 999): ...
_base_ = "./resnest50d_online_AugCosyAAEGray_mlBCE_DoubleMask_lmoRealNBPbr_100e_01_ape_bop_test.py" OUTPUT_DIR = ( "output/gdrn/lmoRealPbrSO/resnest50d_online_AugCosyAAEGray_mlBCE_DoubleMask_lmoRealNBPbr_100e_SO/holepuncher" ) DATASETS = dict(TRAIN=("lmo_pbr_holepuncher_train", "lmo_NoBopTest_holepuncher_train"))
def max_of_min(num1, num2, value1, value2): min_num = min(num1, num2) min_val = min(value1, value2) return max(min_num, min_val)
# # PySNMP MIB module CISCO-TRUSTSEC-SERVER-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/CISCO-TRUSTSEC-SERVER-MIB # Produced by pysmi-0.3.4 at Wed May 1 12:14:38 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3....
# Description: Count number of *.ccp4 (electron density map) files in current directory. # Source: placeHolder """ cmd.do('print("Count the number of ccp4 electron density files in current directory.");') cmd.do('print("Usage: cntccp4s");') cmd.do('myPath = os.getcwd();') cmd.do('ccp4Counter = len(glob.glob1(myPath,...
""" Given n non-negative integers, find the two lines that make the walls of the larges volume of water. Other words: Find two numbers i, j where (j - i) * min(arr[i], arr[j]) is maximized. """ class Solution: def maxArea(self, height): valueMinMaxInds = {} for ind, h in enumerate(height): if h in v...
n = int(input()) d = [0] * 12 d[1] = 1 d[2] = 2 d[3] = 4 def sol(x): if x <= 3: return d[x] else: d[x] = sol(x-1) + sol(x-2) + sol(x-3) return d[x] for _ in range(1, n+1): print(sol(int(input()))) ### 개선 d = [0, 1, 2, 4] for i in range(4,12): d.append(d[i-1]+d[i-2]+d[i-3])...
t=int(input()) while(t): t=t-1 n,m,k=input().split() n,m,k=int(n),int(m),int(k) a,b=min(n,m),max(n,m) c=b-a c1=c-k print(max(c1,0))
def consumer(): r = '' while True: n = yield r if not n:return print('consuming the event %s'%n) r = '200 OK' def produce(c): c.send(None) for n in range(1,6): print('producing event %s'%n) r = c.send(n) print('the consumer response %s'%r) c.c...
def letters( input): return ''.join(filter(str.isalpha, input)) def strip_input_name( input ): return
# lista dentro uma função def criar_baralho(): naipes = ['Paus', 'Espadas', 'Copas', 'Ouro'] cartas = [2, 3, 4, 5, 6, 7, 8, 9, 10, 'A\'s', 'Valete', 'Rainha', 'Rei'] mao = [] for naipe in naipes: for carta in cartas: mao.append(f'{naipe} de {carta}') return mao meu_baralho = c...
print(r"""Switching on camera from habitat with camels... ___.-''''-. /___ @ | ',,,,. | _.'''''''._ ' | / \ | \ _.-' \ | '.-' '-. | ', | '', ...
print('\033[31m Olá! Bem vindo ao exercicio 55\033[m') print('Faça um programa que leia o peso de cinco pessoas. No final, mostre qual foi o maior e o menor peso lidos') maior = 0 menor = 0 for people in range (0,5): peso = float(input('Peso da {} pessoa: '.format(people+1))) if people ==0: maior = p...
# 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...
def print_parentheses(P): stack = list() for p in P: if stack and stack[-1] == '(' and p == ')': stack.pop() print(' ' * len(stack) + p) else: stack.append(p) print(' ' * (len(stack) - 1) + p) print_parentheses('(()((())()))')
peso = [] for i in range (1, 6): x = float(input('Digite o peso da {}º pessoa : '.format(i))) peso.append(x) peso.sort() print('O menor peso medido foi {}'.format(peso[0])) print('O maior peso medido foi {}'.format(peso[-1])) print('A media dos pesos é de {}'.format(sum(peso)/len(peso)))
#Melhore o desafio 61, perguntando para o usuário se ele quer mostrar mais alguns termos. O programa encerará quando o usuário disser que quer mostrar 0 itens. print('╔════════════•ೋೋ•═══════════╗ ') print(' Progressão aritimética v3.0') print('╚════════════•ೋೋ•═══════════╝') termo = int(input('Primeiro termo: ')) raza...
print('准备写一个项目') print('user') print('film') print('ceneama') print('seat') print('ticket')
#encoding utf-8 #__author__ = Jonas Duarte, duarte.jsystem@gmail.com #Python3 __author__ = 'Jonas Duarte' class Gera_query(object): def __init__(self): self.query = "" def nova_tabela(self, banco_de_dados, nova_tabela): self.query = f"CREATE TABLE `{banco_de_dados}`" self.query += f...
# Atur cara untuk mengira Body Mass Index (BMI) # Kumpulan Syabil & Amir # Dibuat oleh Amir # Output print("***Atur Cara Untuk Mengira BMI Anda***\n") # Input tinggi = input("Masukkan ketinggian anda (Meter): ") berat = input("Masukkan berat badan anda (KG): ") # Function - mengetahui jika value ialah float atau tid...
n = int(input('Digite um número: ')) if n < 1: print('IIIIII é bem pequeno') elif n < 7: print('ÉEEE bais ou benos') else: print('Que grandão')
n1 = float(input('Digite um número: ')) n2 = float(input('Digite um número: ')) n3 = float(input('Digite um número: ')) if n1 > n2 and n1 > n3: print(f'O MAIOR valor digitado foi {n1}.') if n1 < n2 and n1 < n3: print(f'O MENOR valor digitado foi {n1}.') if n2 > n1 and n2 > n3: print(f'O MAIOR valor digita...
"""Below Python Programme demonstrate rstrip functions in a string""" #Example: random_string = ' this is good' # Leading whitepsace are removed print(random_string.rstrip()) # Argument doesn't contain 'd' # No characters are removed. print(random_string.rstrip('si oo')) print(random_string.rstrip('sid oo'))
# caption dataset class caption_dataset(torch.utils.data.Dataset): def __init__(self, captions, path, tokenizer, max_len, mode): self.captions = captions self.path = path self.tokenizer = tokenizer self.max_len = max_len self.mode = mode self.start = self.tokenizer.convert_tokens_to_ids('[sta...
# from django.conf.urls import url # from . import views urlpatterns = [ # url(r'^change-profile/$', # views.change_own_profile, name='change-profile'), ]
class GroupNotFoundException(Exception): pass class UserNotFoundException(Exception): pass class AlreadyExistsOnDatabaseException(Exception): pass class ChatIdOrTextCannotBeEmpty(Exception): pass
X_threads = 16 Y_threads = 1 Invoc_count = 1 start_index = 0 end_index = 0 src_list = ["needle_kernel.cu", "needle.h"] SHARED_MEM_USE = True total_shared_mem_size = 2.18*1024 domi_list = [481] domi_val = [0]
def fib(max): a, b, n = 0, 1, 0 while n < max: yield b a, b = b, a + b n += 1 print('done') for i in fib(6): print(i) def test(name, age, *args, city, country): print(name, age, args, city, country) test('kaka', 23, 45, city='test', country = 'China') def f1(a, b, c = 0, *args, **kw): print('a = ',a,...
def init_grid(size=3): """Returns an empty Tic-tac-toe grid with measurements size x size""" # make nested list with list comprehension return [[' ' for col in range(size)] for row in range(size)] def print_grid(grid): """Prints the grid""" # empty line for better readability print() ...
# 스타 수열 def solution(a): """ get longest length of subsequence that satisfy star-sequence Args: a(list): sequence Returns(int): longest length of subsequence """ res = 0 numbers = set() counts = [0] * (len(a) + 1) for num in a: numbers.add(num) counts[num...
class Tardis(object): def __init__(self): super().__init__() def camouflage(self): raise NotImplementedError('You should implement this in a subclass') class TardisChild(Tardis): def camouflage(self): return 'Yay! Overridden' if __name__ == "__main__": # Will raise exception...
## @package Connection Connection object that used by Configuration editor ## The class that has all the information about a connection between two modules class Connection: ## Constructor # @param self Object pointer # @param model1 A Module object of one connected module # @param model2 A module object of th...
''' Version and license information. ''' __all__ = ['__version__', '__versiondate__', '__license__'] __version__ = '1.2.3' __versiondate__ = '2021-08-27' __license__ = f'Sciris {__version__} ({__versiondate__}) – © 2021 by Sciris.org'
"""Constants for Squeezebox emulation.""" PROV_ID = "squeezebox" PROV_NAME = "Squeezebox emulation"
#!/usr/bin/env python """ Base package for the jet-hadron correlation analysis. .. codeauthor:: Raymond Ehlers <raymond.ehlers@cern.ch>, Yale University """ __all__ = [ "analysis_config", "analysis_objects", "params", ]
# Employee info class Employee: def __init__(self, id, importance, subordinates): # It's the unique id of each node. # unique id of this employee self.id = id # the importance value of this employee self.importance = importance # the id of direct subordinates ...
'''Subtypes of str used as names ''' Role = str '''Basic identifier for a Node. ''' # TODO: Suprress inherited docstrings from str str = str '''The name of components such as endpoints and loops '''
# This file is for import testing # nah, nvm i will do my testing here cause i don't wanna delete the test.py file class SeriesMixed: def __init__(self): self.series_side = input('[T]op or [B]ottom or [Both]:') if self.series_side.lower() == 't': self.top_value = list(map(int,...
def inc(x): x = x + 1 print(x) y = 10 inc(y) print(y)
# -*- encoding: utf-8 -*- # Abrimos el archivo para leerlo filehandler = open('data.txt', 'r') data = [] for line in filehandler: line = line.strip('\n') line = line.split() line = [float(item) for item in line] data.append(line) filehandler.close() num = 0.0 den = 0.0 alpha = 1 for z, d in data: ...
class Clause(object): def __init__(self, clause): """Initializes a clause. Here, the input clause is either a list or set of integers, or is an instance of Clause; in the latter case, a shallow copy is made, so that one can modify this clause without modifying the original clause. ...
### def cheese_and_crackers(cheese_count, boxes_of_crackers): # print(f"cheese_count: {cheese_count}, boxes_of_crackers: {boxes_of_crackers}") # cheese_and_crackers = (input("How many cheese do you have"), input ("How many crackers you have?")) # print(" we can do combine the two, variable and math:") # cheese...
"""DTO that holds all information about word, its stem and assigned group""" class ProcessingEntry: def __init__(self, org): """Initialize ProcessingEntry class""" self.__org = org self.__stem = org self.__group = -1 self.__is_exemplar = False @property def org(se...
#!/usr/bin/env python # -*- coding: utf-8 -*- """Constants for APRS Module Tests.""" __author__ = 'Greg Albrecht W2GMD <gba@orionlabs.co>' __license__ = 'Apache License, Version 2.0' __copyright__ = 'Copyright 2015 Orion Labs, Inc.' TEST_FRAMES = 'tests/test_frames.log'
line = input().split() n = int(line[0]) k = int(line[1]) line = [int(i) for i in input().split()] counter = 0 for j in line: if(5 - j >= k): counter += 1 print(str(counter//3))
# coding: utf-8 def array_values(arr): if isinstance(arr, dict): return arr.values() return arr[:] if __name__ == '__main__': array = {"size": "XL", "color": "gold"} print(array_values(array))
class Node: def __init__(self, key=0, data=0): self.data = data self.key = key self.prev = None self.next = None class LRUCache: def __init__(self, capacity: int): self.capacity = capacity self.lookup = {} self.size = 0 self.head = Node() ...
# ============================================================================ # 第二章 単位住戸の一次エネルギー消費量 # 第四節 特定建築主基準 # Ver.05(エネルギー消費性能計算プログラム(住宅版)Ver.02~) # ============================================================================ def get_E_ST_star(E_SH, E_SC, E_SV, E_SL, E_SW, E_SM, reference): """基準一次エネルギー消費量 ...
""" 15781 : 헬멧과 조끼 URL : https://www.acmicpc.net/problem/15781 Input #1 : 5 7 10 60 15 20 7 1 2 3 7 5 1 3 Output #1 : 67 Input #2 : 2 3 1 1000000000 20 18 1000000000 Output #2 : 2000000000 """ input() helmet = max(list(map(int, inp...
# -*- coding: utf-8 -*- """ Created on Tue Mar 23 14:11:08 2021 @author: asagar """ def static_rules(): # rules defined and more can be added # ref: https://en.wikipedia.org/wiki/Tuple # ref:https://www.proz.com/kudoz/english/other/526192-2%3Ddouble3%3Dtriplewhats-for-456etc.html rules = {'numbers':...
# -*- Mode: Python; tab-width: 4 -*- # SMR 2012: originally from dynwin, circa 1995 ########################################################################### # regions ########################################################################### # # do two rectangular regions intersect? # # +---> # | lb,tb...
class Node: def __init__(self, value=None, next_node=None): self.value = value self.next_node = next_node # build a class to manage nodes class LinkedList: def __init__(self): self.head = None # stores a node that is the begining of the list self.tail = None # stores a node ...
# Prints sum count = sum = 0 while True: n = int(input('Digite um valor (999 para parar): ')) if n == 999: break count += 1 sum += n print(f'A soma dos {count} valores foi {sum}!')
def Rotate(arr): temp=[] for i in range(len(arr)): for j in range(0,len(arr)): if i != j and i < j : arr[i][j],arr[j][i]=arr[j][i],arr[i][j] for l in arr: l.reverse() print(l) arr=[[1,2,3], [4,5,6], [7,8,9]] Rotate(arr)
class Form(GenericForm, IDisposable): """ An object that represents a Form within the Autodesk Revit Massing Family. """ def AddEdge(self, *__args): """ AddEdge(self: Form,faceReference: Reference,point: XYZ) Add an edge to the form,connecting two edges on different profiles,by a s...
expected_output = { "on_demand_tunnel":{ "20":{ "system-ip":"20.0.0.20", "on-demand":"no" }, "21":{ "system-ip":"21.0.0.21", "on-demand":"yes", "status":"inactive" }, "22":{ "system-ip":"22.0.0.22", ...
class FieldMetaMixin: @classmethod def get_field_meta(cls, field_name): return cls._meta.get_field(field_name).get_meta() @classmethod def has_field_meta(cls, field_name): return hasattr(cls._meta.get_field(field_name), "_meta") \ and cls.get_field_meta(field_name) is not...
# loop through a string s = "string" #Version 1 for i in s: print(i) #version 2 for i in range(len(s)): print(s[i])
def to_str(data): return str(data), None def to_list(data): return [data], None def to_int(data): try: return int(data), None except ValueError: return data, None
""" # Definition for a Node. class Node: def __init__(self, x: int, next: 'Node' = None, random: 'Node' = None): self.val = int(x) self.next = next self.random = random """ class Solution: def copyRandomList(self, head: 'Node') -> 'Node': if not head: return None ...
CONFIG = { "testing": False }
def path_exists(node1, node2, G): """ This function checks whether a path exists between two nodes (node1, node2) in graph G. Special thanks to @ghirlekar for suggesting that we keep track of the "visited nodes" to prevent infinite loops from happening. This also removes the need to remove node...
words= [] # this opens the text file that contains a english lanuage dictionary with open("words.txt") as data: datalines = (line.rstrip('\r\n') for line in data) for line in datalines: words.append(line.lower()) # these are test shreds in a list of lists. Each list represents the words you kight find ...
# https://rosalind.info/problems/kmp/ def fmtfa(fasta: list): prev = True header = [] seq = [] for f in fasta: if ">" in f: header.append(f[1:]) prev = True elif prev: seq.append(f) prev = False else: seq[-1] += f ...
###################### # Choose dataset: # ###################### dataset = 'eight' ######### # Data: # ######### weighted = False scaler = 1. ############## # Training: # ############## lr = 1e-3 batch_size = 2048 gamma = 0.995 weight_decay = 1e-5 betas = (0.9, 0.999) n_epochs = 200 n_its_per_epoch = 1 #####...
##6 bir mükemmel sayıdır. Çünkü 6’nın pozitif bölenleri 1,2,3 ve 6’dır. # Kendisi hariç diğer bölenlerini toplarsak 1+2+3=6 eder.### def mukemmel(sayi): rakam=0 for i in range(1,sayi): if sayi%i==0: rakam+=i if rakam==sayi: print (sayi," mukemmel sayidir.") else: ...
uyir = ["அ", "ஆ", "இ", "ஈ", "உ", "ஊ", "எ", "ஏ", "ஐ", "ஒ", "ஓ", "ஔ"] mei = [ "க்", "ங்", "ச்", "ஞ்", "ட்", "ண்", "த்", "ந்", "ப்", "ம்", "ய்", "ர்", "ல்", "வ்", "ழ்", "ள்", "ற்", "ன்", ] uyirmei = [ ["க", "கா", "கி", "கீ", "கு", "கூ", "கெ", "கே"...
class AndroidViewport: def __init__(self, native): self.native = native self.dpi = 96 # FIXME This is almost certainly wrong... # self.dpi = ... self.interface.app._impl.device_scale @property def width(self): return self.native.ClientSize.Width @property def heig...
puzzle_input = input("> ") MIN, MAX = (int(x) for x in puzzle_input.split("-")) # PART 1 def is_ordered(n): return list(str(c)) == sorted(str(c)) def has_double(n): return len(set(str(n))) < len(str(n)) c = MIN matching = 0 while c <= MAX: if is_ordered(c): if has_double(c): matching +...
# AUTOGENERATED BY NBDEV! DO NOT EDIT! __all__ = ["index", "modules", "custom_doc_links", "git_url"] index = {} modules = [] doc_url = "https://chho-work.github.io/biolab/" git_url = "https://github.com/chho-work/biolab/tree/main/" def custom_doc_links(name): return None
"""The common ANTLR rule implementation.""" load(":lang.bzl", "C", "CPP", "GO", "PYTHON", "PYTHON2", "PYTHON3") AntlrInfo = provider( fields = { "sources": "The generated source files.", "headers": "For C/C++ the generated header files.", "data": "Additional ANTLR data files", }, d...
# Describe an image # mean (c) 2011 # FMT_NTSC=0 FMT_PAL=1 FMT_FILM=2 FMT_UNKNOWN=-3 AR_1_1=0 AR_4_3=1 AR_16_9=2 # # # class resizer(object): def __init(self): self.width=0 self.height=0 self.topbottom=0 self.leftright=0 self.ar=ADM_image.AR_1_1 # # # # class image: def...
strategies = 0 def fit(current_value, max_val): global strategies, available_coins, goal_value if current_value == goal_value: strategies = strategies + 1 return remaining_value = goal_value - current_value end = min(remaining_value, max_val) if end == 1: strategies += 1...
# Estrutura de dados - Listas nomes = ["Amanda","Bruno","Camila","Davi","Elen","Felipe"] for i in range(0,6,2): print(nomes[i])
#!/usr/bin/env python3 class ActionLight: def __init__(self, funcName, func): self.funcName = funcName self.func = func self.resourceType = False self.pending = True self.max_depth = 0 def equals(self, other): # TODO: should we compare func? return (t...
# # @lc app=leetcode.cn id=553 lang=python3 # # [553] 最优除法 # # https://leetcode-cn.com/problems/optimal-division/description/ # # algorithms # Medium (51.32%) # Total Accepted: 622 # Total Submissions: 1.2K # Testcase Example: '[1000,100,10,2]' # # 给定一组正整数,相邻的整数之间将会进行浮点除法操作。例如, [2,3,4] -> 2 / 3 / 4 。 # # # 但是,你可以...
# Must have device = ['RTR02'] mode = 'collect' # collect, compare ,commit , commit_only, 'jsnapy_pre', 'jsnapy_post' playbook_summary = 'Check interfaces' custom_def = False # conditional # if mode = commit or commit_only commit_comments = 'commit_comments' # if mode not jsnapy_*,commit only commands = ['show versio...
################################################################################# # Class ConlluData # # represents a token (a row of 10 columns) in CoNLLU format # # Author: Ika Alfina (ika.alfina@cs.ui.ac.id) # ################################################################################# class ConlluData: def ...
class Solution: def cheapestJump(self, A, B): n = len(A) preMin = {n - 1:[n]} for i in range(n - 2, -1, -1): if A[i] == -1: continue mn, preIndex = float("inf"), None for ind in range(i + 1, i + B + 1 <= n and i + B + 1 or n): ...
non_valid_licenses_rdf = """@prefix odrl: <http://www.w3.org/ns/odrl/2/> . @prefix cc: <http://creativecommons.org/ns#> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . <http://example.org/License/1> a odrl:Policy ; rdfs:label "not valid:CommercialUse should not be a Duty" ; odrl:Duty cc:Notice, ...
print('Calcular a área do quadradado') lado = int(input('Insira o tamanho do lado: ')) area = lado * lado print('O dobro da area do quadrado é: ' + str(area * 2))
"""Integer to Roman Given an integer, convert it to roman numberal. Input is guaranteed to be within the range from 1 to 3999. Roman numerals are represented by seven different symbols: I, V, X, L, C, D and M. Symbol Value I 1 V 5 X 10 L 50 C 100 D ...
# -*- coding: utf-8 -*- """ Python package of code for Gaussian process classification experiments. """ __authors__ = 'Matt Graham' __copyright__ = 'Copyright 2015, Matt Graham' __license__ = 'MIT'
# -*- encoding: utf-8 -*- # ! python3 default_app_config = 'web.apps.WebAppConfig'
# 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 ...
#!/usr/bin/env python ref_file = open('../../../result/PhastCons46Ways_miRBase_v21_hg38Tohg19_kmeans5_2015-07-17.txt','r') input_file = open('../../../data/mirMark/S1_site-level_human_miRNA-target_site_pairs_from_miRecords_id-seq.txt','r') output_file = open('../../../result/PhastCons46Ways_miRBase_v21_hg38Tohg19_...
# https://www.codewars.com/kata/array-mash/python def array_mash(a, b): mesh = [] for one, two in zip(a, b): mesh.extend([one, two]) return mesh