blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 288 | content_id stringlengths 40 40 | detected_licenses listlengths 0 112 | license_type stringclasses 2
values | repo_name stringlengths 5 115 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 684
values | visit_date timestamp[us]date 2015-08-06 10:31:46 2023-09-06 10:44:38 | revision_date timestamp[us]date 1970-01-01 02:38:32 2037-05-03 13:00:00 | committer_date timestamp[us]date 1970-01-01 02:38:32 2023-09-06 01:08:06 | github_id int64 4.92k 681M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 22
values | gha_event_created_at timestamp[us]date 2012-06-04 01:52:49 2023-09-14 21:59:50 ⌀ | gha_created_at timestamp[us]date 2008-05-22 07:58:19 2023-08-21 12:35:19 ⌀ | gha_language stringclasses 147
values | src_encoding stringclasses 25
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 128 12.7k | extension stringclasses 142
values | content stringlengths 128 8.19k | authors listlengths 1 1 | author_id stringlengths 1 132 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
cb518cf4285b1538c6a12b8b2b0d80ae2cf354a2 | fab7b6e422b74424fb59398635f74faca9ff5a58 | /waimak_extended_boundry/model_and_NSMC_build/targets/well_bulding_script.py | f2f0b033d08be8757829d48282d0a4eece8d3768 | [] | no_license | hansonmcoombs/Waimakariri-Model-Ashley-to-Selwyn | c7a56a2ebd0d421c9679cb4a16ae319dfb2041b1 | c96c2663b010975ec08d42840fbc7970f3c2b085 | refs/heads/master | 2023-05-29T10:57:33.916912 | 2020-04-23T21:32:21 | 2020-04-23T21:32:21 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 732 | py | # -*- coding: utf-8 -*-
"""
Author: mattH
Date Created: 25/07/2017 11:13 AM
"""
import pandas as pd
import numpy as np
import flopy_mh as flopy
#this script was passed to brioch for inclusion in the pest optimisation process
# the influx wells are presently set to 1 m3/s so the muliplier can range between 0 and 5
wel... | [
"hansonmcoombs@gmail.com"
] | hansonmcoombs@gmail.com |
781488f21981ce3a35f5823fd69ba77f85484509 | f82e67dd5f496d9e6d42b4fad4fb92b6bfb7bf3e | /scripts/client/gui/dialogsinterface.py | 01e537573c7b9639810015d345977ad9df740966 | [] | no_license | webiumsk/WOT0.10.0 | 4e4413ed4e7b00e22fb85d25fdae9400cbb4e76b | a84f536c73f86d9e8fab559e97f88f99f2ad7e95 | refs/heads/master | 2021-01-09T21:55:00.662437 | 2015-10-23T20:46:45 | 2015-10-23T20:46:45 | 44,835,654 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,750 | py | # Embedded file name: scripts/client/gui/DialogsInterface.py
from gui.Scaleform.Waiting import Waiting
from gui.battle_control import g_sessionProvider
from gui.shared import events, g_eventBus
from gui.shared.utils.decorators import dialog
from gui.shared.utils.functions import showInformationDialog, showConfirmDialog... | [
"info@webium.sk"
] | info@webium.sk |
35356795d538348ce21e6b7b7d750bc012feb21d | 29da2ca6def1270be13a3096685a8e5d82828dff | /CIM14/IEC61970/Dynamics/TurbineGovernors/TurbineGovernor.py | 8395e78690c1c031b3d3c2f1fa248e1347a8fed4 | [
"MIT"
] | permissive | rimbendhaou/PyCIM | 75eb3bcd3729b2410c03f3d5c66d6f1e05e21df3 | d578bb0bf1af344342bd23344385ed9c06c2d0ee | refs/heads/master | 2022-04-28T01:16:12.673867 | 2020-04-16T02:19:09 | 2020-04-16T02:19:09 | 256,085,381 | 0 | 0 | MIT | 2020-04-16T02:15:20 | 2020-04-16T02:08:14 | null | UTF-8 | Python | false | false | 1,608 | py | # Copyright (C) 2010-2011 Richard Lincoln
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to
# deal in the Software without restriction, including without limitation the
# rights to use, copy, modify, merge, publish... | [
"rwl@thinker.cable.virginmedia.net"
] | rwl@thinker.cable.virginmedia.net |
599294b469224e38ff049081aca36eb3ce3d2e2f | bc441bb06b8948288f110af63feda4e798f30225 | /pipeline_sdk/model/resource_manage/filter_condition_pb2.py | 8ca58da50e2eaaea09cd76d058b1eaa644f6a04f | [
"Apache-2.0"
] | permissive | easyopsapis/easyops-api-python | 23204f8846a332c30f5f3ff627bf220940137b6b | adf6e3bad33fa6266b5fa0a449dd4ac42f8447d0 | refs/heads/master | 2020-06-26T23:38:27.308803 | 2020-06-16T07:25:41 | 2020-06-16T07:25:41 | 199,773,131 | 5 | 0 | null | null | null | null | UTF-8 | Python | false | true | 4,173 | py | # -*- coding: utf-8 -*-
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: filter_condition.proto
import sys
_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.pro... | [
"service@easyops.cn"
] | service@easyops.cn |
1b6353b6528b8a595913455a59dab726fa53fa19 | 95eed88115075f7e1916a14de7497d05a12a9330 | /abc106d.py | f7b6d1f202fe22e2ff2f13477e4221a8bc71c642 | [] | no_license | ynagi2/atcoder | bdbbd030f1dd39e937b0872b028ce0f38372521e | e404f4500d837bfd6ca473aa2837f46ae71ad84a | refs/heads/master | 2022-04-29T12:48:44.229462 | 2022-04-22T15:04:50 | 2022-04-22T15:04:50 | 241,098,529 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 757 | py | # pypyにする
def main():
n, m, Q = map(int, input().split())
lr = [[0]*(n+1) for _ in range(n+1)]
for _ in range(m):
l, r = map(int, input().split())
lr[l][r] += 1
p = []
for _ in range(Q):
_list = list(map(int, input().split()))
p.append(_list)
sums = []
for l... | [
"noreply@github.com"
] | ynagi2.noreply@github.com |
b0df1d3b85cb9522c935158901ae2bddeaecc037 | a2e1ade428b26fd9009d1ab9e6594f06755ec5a4 | /src/saas/bkuser_shell/categories/serializers.py | 7fce74839512a4fc3584e570c807f34b56a1f0c0 | [
"MIT"
] | permissive | luyouli/bk-user | f285c5ee415cfc8769727b16e3d75ecce3b469d5 | 8ea590958a5c6dd3c71d0b72e1d4866ce327efda | refs/heads/master | 2023-08-07T20:58:36.429072 | 2021-08-24T07:02:32 | 2021-08-24T07:02:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,716 | py | # -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making 蓝鲸智云-用户管理(Bk-User) available.
Copyright (C) 2017-2021 THL A29 Limited, a Tencent company. All rights reserved.
Licensed under the MIT License (the "License"); you may not use this file except in compliance with the Lic... | [
"bluesedenyu@gmail.com"
] | bluesedenyu@gmail.com |
a9b4edb83b779b911c53957fae262072b357d724 | c426f269e8f7598d78b0a3bcc5629bfe447d12f6 | /4_Interactive Programming Python (RICE)/MiniProjects/MiniProject3_StopWatch/MiniProject3_v02_user12_DNqZOhd30O_8.py | 322dcf356f777ff0c51ef0d4d02f84a38c735015 | [] | no_license | DmitryVakhrushev/Python | 8d05d083f63822622f43ea5d873b98ef4e8cfd15 | 9dd2f37bcdce25a5cc0146adb4513ed2e539b650 | refs/heads/master | 2022-11-13T18:39:44.131820 | 2020-06-28T02:29:17 | 2020-06-28T02:29:17 | 243,847,823 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,336 | py | # template for "Stopwatch: The Game"
import simplegui
import time
# define global variables
curTime = 0
# define helper function format that converts time
# in tenths of seconds into formatted string A:BC.D
def format(t):
minutes = str(t // 600)
if ((t - (t//600)*600) // 10) < 10:
seconds =... | [
"dm.vakhrushev@gmail.com"
] | dm.vakhrushev@gmail.com |
145f4d44a7d58355228c02ba21b610bc4e85e637 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02619/s875095596.py | 54f8a5836b379689a3036484bd7fc2bf077aa557 | [] | no_license | Aasthaengg/IBMdataset | 7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901 | f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8 | refs/heads/main | 2023-04-22T10:22:44.763102 | 2021-05-13T17:27:22 | 2021-05-13T17:27:22 | 367,112,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 434 | py | import sys
def input():
return sys.stdin.readline()[:-1]
d = int(input())
c = list(map(int, input().split()))
C = sum(c)
s = [list(map(int, input().split())) for _ in range(d)]
t = [int(input()) for _ in range(d)]
def score(t):
res = 0
minus = 0
last = [0 for _ in range(26)]
for i, x in enumerate(t):
minus += C... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
fbd1236ee2905d9e213d9ee829032acb53361778 | 20b4be7df5efeb8019356659c5d054f29f450aa1 | /API/gdax/__init__.py | 152d1b6d1e91f266693e8c11ceadc560286aec43 | [
"Apache-2.0",
"MIT"
] | permissive | kumars99/TradzQAI | 75c4138e30796573d67a5f08d9674c1488feb8e4 | 1551321642b6749d9cf26caf2e822051a105b1a5 | refs/heads/master | 2020-03-29T20:14:45.562143 | 2018-09-25T16:07:21 | 2018-09-25T16:07:21 | 150,302,554 | 1 | 0 | null | 2018-09-25T17:17:54 | 2018-09-25T17:17:54 | null | UTF-8 | Python | false | false | 174 | py | from .authenticated_client import AuthenticatedClient
from .public_client import PublicClient
from .websocket_client import WebsocketClient
from .order_book import OrderBook
| [
"awakeproduction@hotmail.fr"
] | awakeproduction@hotmail.fr |
f4269983761d21127d14240f5c8bf6a09d96ad3c | 05c70f2396e81328b1e8e1155994fccd52104fad | /databricks/notebooks/tools/mlflow_http_client.py | 14e17b5444eeec41c8a515e81d1abbf48a21d165 | [] | no_license | amesar/mlflow-fun | 0e015189e546f39b730375b292288bac1210fb88 | 31b575b97329e78bd9b0c062a270e7375f10e170 | refs/heads/master | 2023-05-13T04:55:57.367744 | 2022-11-28T16:24:12 | 2022-11-28T16:24:12 | 142,216,836 | 27 | 15 | null | 2023-05-09T18:06:50 | 2018-07-24T21:56:27 | Python | UTF-8 | Python | false | false | 1,420 | py | # Databricks notebook source
# MAGIC %md ### MlflowHttpClient - Requests Client for MLflow REST API
# MAGIC * See: https://mlflow.org/docs/latest/rest-api.html
# MAGIC * See notebook [test_mlflow_http_client](https://demo.cloud.databricks.com/#notebook/3652184) for usage
# COMMAND ----------
import requests
class Ml... | [
"amesar@users.noreply.github.com"
] | amesar@users.noreply.github.com |
2b766768a039858cfcc739797460163dfe150e89 | 1651184ccacf43c6a87864d5f0e4b4ea5453b98c | /backend/users/migrations/0002_auto_20201219_1700.py | d0e8017c1750c87d4aa5fd91ad4684584641a8a0 | [] | no_license | crowdbotics-apps/the-jumper-app-23425 | b20ef6908e2c4c2269dfba6d109d246044e10a08 | 470b864f8a8ae9638075c734709ae2b9aed1c7b4 | refs/heads/master | 2023-01-31T04:53:08.499998 | 2020-12-19T18:18:34 | 2020-12-19T18:18:34 | 322,364,725 | 0 | 0 | null | 2020-12-19T20:19:10 | 2020-12-17T17:22:56 | Python | UTF-8 | Python | false | false | 1,275 | py | # Generated by Django 2.2.17 on 2020-12-19 17:00
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("users", "0001_initial"),
]
operations = [
migrations.AddField(
model_name="user",
name="last_updated",
... | [
"team@crowdbotics.com"
] | team@crowdbotics.com |
18adf7ef8f6ea9f3c2adfaaf8f694d42fb2d2a72 | 3880497e60f93cec22b86e1d77cf68c6546b4c51 | /liyida2/settings.py | 53eb68e450a685fe0cc0eb04826a663bef63e6bc | [] | no_license | li-yi-da/liyida_blog | b63ac1bf2add1a6a7d4b2af0a8a2e07c3d5c89ea | 32306f84f45a4f633de2bef17621a4b09d3120f8 | refs/heads/master | 2020-05-16T03:39:22.664695 | 2019-04-26T09:57:40 | 2019-04-26T09:57:40 | 182,736,436 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,968 | py | """
Django settings for liyida2 project.
Generated by 'django-admin startproject' using Django 2.1.2.
For more information on this file, see
https://docs.djangoproject.com/en/2.1/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/2.1/ref/settings/
"""
... | [
"root@vultr.guest"
] | root@vultr.guest |
6df7faaace8e0d5146130f9fa68b5334f410dd30 | 61296b98e4d481893db4bc51d75652c7109ae626 | /0000_examples/xym_rrtcplanning_exe.py | b5c6912ba577bb01987d0e8664f3507732e13f06 | [
"MIT"
] | permissive | Shogo-Hayakawa/wrs | 23d4560b1062cf103ed32db4b2ef1fc2261dd765 | 405f15be1a3f7740f3eb7d234d96998f6d057a54 | refs/heads/main | 2023-08-19T19:29:15.409949 | 2021-11-02T01:22:29 | 2021-11-02T01:22:29 | 423,663,614 | 0 | 0 | MIT | 2021-11-02T00:59:17 | 2021-11-02T00:59:17 | null | UTF-8 | Python | false | false | 2,732 | py | import math
import numpy as np
import visualization.panda.world as wd
import modeling.geometric_model as gm
import modeling.collision_model as cm
import robot_sim.robots.xarm7_shuidi_mobile.xarm7_shuidi_mobile as xav
import motion.probabilistic.rrt_connect as rrtc
import robot_con.xarm_shuidi.xarm.xarm_client as xac
b... | [
"wanweiwei07@gmail.com"
] | wanweiwei07@gmail.com |
a1e0d8b350d7ea0d8ccb0adaee667c82278dcfde | 3a02bff6397eb23afd55cc17faf81c24a8751f2d | /fsoft/Week 1/B2/bai20.py | 78996fb509a0e64714b00daeed6da53583635b3e | [] | no_license | cothuyanninh/Python_Code | 909fd4d798cbd856e8993f9d4fea55b4b7c97a1f | 7f657db61845cf8c06725a2da067df526e696b93 | refs/heads/master | 2022-11-06T01:00:39.939194 | 2019-01-13T15:27:38 | 2019-01-13T15:27:38 | 164,468,626 | 0 | 1 | null | 2022-10-13T16:16:21 | 2019-01-07T17:40:51 | Python | UTF-8 | Python | false | false | 225 | py | ip_src = input("Type: ").split(".")
ip_new_list = [int(i) for i in ip_src]
print(ip_new_list)
# print("."join(str(i) for i in ip_new_list))
result = ""
for i in ip_new_list:
result += str(i)
result += "."
print(result[:-1]) | [
"cothuyanninh@gmail.com"
] | cothuyanninh@gmail.com |
7a3099b7410237ec975d64598d9a19e6bbc19740 | e0760295cc8221dff41af7e98fb49dd77a8fca1e | /test_product_of_array_except_self.py | b3526de15d4571ac8cb2f5f5b3b01d1af6372d91 | [
"MIT"
] | permissive | jaebradley/leetcode.py | 422dd89749482fd9e98530ca1141737a6cdbfca4 | b37b14f49b4b6ee9304a3956b3b52f30d22fac29 | refs/heads/master | 2023-01-24T08:32:11.954951 | 2023-01-18T13:21:56 | 2023-01-18T13:21:56 | 177,721,059 | 1 | 0 | MIT | 2021-07-23T03:52:32 | 2019-03-26T05:32:18 | Python | UTF-8 | Python | false | false | 358 | py | from unittest import TestCase
from product_of_array_except_self import Solution
class TestProductOfArrayExceptSelf(TestCase):
def test_values(self):
self.assertEqual(Solution().productExceptSelf([1, 2, 3, 4]), [24, 12, 8, 6])
def test_values_2(self):
self.assertEqual(Solution().productExcept... | [
"jae.b.bradley@gmail.com"
] | jae.b.bradley@gmail.com |
613a1e04c91353377a76461f50ec234ef3598ccd | 472578974401c83509d81ea4d832fc3fd821f295 | /python资料/day8.7/day06/exercise03.py | 61083cd262387074b83c85661c8b524df53d0abd | [
"MIT"
] | permissive | why1679158278/python-stu | f038ec89e9c3c7cc80dc0ff83b76e7c3078e279e | 0d95451f17e1d583d460b3698047dbe1a6910703 | refs/heads/master | 2023-01-05T04:34:56.128363 | 2020-11-06T09:05:16 | 2020-11-06T09:05:16 | 298,263,579 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 427 | py | # 使用列表推导式
# 生成1--50之间能被3或者5整除的数字
# 生成5 -- 100之间的数字平方
# list_result = []
# for number in range(1, 51):
# if number % 3 == 0 or number % 5 == 0:
# list_result.append(number)
list_result = [number for number in range(1, 51) if number % 3 == 0 or number % 5 == 0]
print(list_result)
list_result = [number ** 2... | [
"1679158278@qq.com"
] | 1679158278@qq.com |
09094452c5150588bd91de1f510c8944c0d702c4 | dfd1dba6fa990810b9609bd25a433c974ab2098d | /backend/purple_cloud_1/urls.py | c766a76997628b9a2824319a8a1a930b4daed168 | [] | no_license | saaaab1213/purple-cloud-1 | fbc54e73e2ba5bf6ed1db3acc9d2357031985343 | 10651eaf6ec13a656ed456ab9bfe504691e1d49d | refs/heads/master | 2023-02-08T02:46:46.009493 | 2021-01-05T09:54:22 | 2021-01-05T09:54:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,987 | py | """purple_cloud_1 URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/2.2/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: path('', views.home, name='home')
Clas... | [
"lorence@crowdbotics.com"
] | lorence@crowdbotics.com |
132ec6ef5bb76e2e07bc3e2a9960380a2a326fb4 | 88064e96a4ce3aaa472222c8f294799655e923b8 | /lesson07/exercise4.py | b8277aa2405a2c1a73075dafeb8f5860d524cbe7 | [] | no_license | manosxatz/python | 52d91b42dcd3e516296811a036f23a988542008d | 789f2306f7c6c1ad798c228000bb0d49e99c9629 | refs/heads/master | 2022-11-09T18:46:54.002464 | 2020-06-24T16:57:19 | 2020-06-24T16:57:19 | 275,238,123 | 1 | 0 | null | 2020-06-26T20:05:26 | 2020-06-26T20:05:26 | null | UTF-8 | Python | false | false | 929 | py | from random import seed
from random import randrange
from datetime import datetime # all 3 at the beginning
seed(datetime.now()) # once, before randint call
N = 30
pupils = set()
for number in range(N):
pupils.add("pupil" + str(number))
list_pupils = list(pupils)
math_teams = set()
for _ in rang... | [
"noreply@github.com"
] | manosxatz.noreply@github.com |
f1b5ec65d65f614da16fa1d29140d2ba61bc3f54 | 6527b66fd08d9e7f833973adf421faccd8b765f5 | /yuancloud/addons/report_webkit/__yuancloud__.py | 4dff514cfa8d054469a394cd8baa16fae6ecef04 | [] | no_license | cash2one/yuancloud | 9a41933514e57167afb70cb5daba7f352673fb4d | 5a4fd72991c846d5cb7c5082f6bdfef5b2bca572 | refs/heads/master | 2021-06-19T22:11:08.260079 | 2017-06-29T06:26:15 | 2017-06-29T06:26:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,700 | py | # -*- coding: utf-8 -*-
# Part of YuanCloud. See LICENSE file for full copyright and licensing details.
# Copyright (c) 2010 Camptocamp SA (http://www.camptocamp.com)
# Author : Nicolas Bessi (Camptocamp)
{
'name': 'Webkit Report Engine',
'description': """
This module adds a new Report Engine based on WebKit... | [
"liuganghao@lztogether.com"
] | liuganghao@lztogether.com |
d216baf5afc15e5e4d3d49a521a2e2b3a26e18d2 | 9dde5311a5fe0357995a737eb8bc9b54a5cc21d8 | /betago/processor.py | 1fee7dd7acbbda0d32df2d67e948e987fa3f981f | [
"MIT"
] | permissive | maxpumperla/betago | 08163cbc5a61d4c5e19fd59adc4299a19427ec90 | ff06b467e16d7a7a22555d14181b723d853e1a70 | refs/heads/master | 2023-08-21T14:48:53.854515 | 2020-12-22T08:33:54 | 2020-12-22T08:33:54 | 56,266,535 | 747 | 192 | MIT | 2019-11-18T09:45:36 | 2016-04-14T20:02:28 | Python | UTF-8 | Python | false | false | 7,497 | py | from __future__ import absolute_import
import numpy as np
from .dataloader.base_processor import GoDataProcessor, GoFileProcessor
from six.moves import range
class SevenPlaneProcessor(GoDataProcessor):
'''
Implementation of a Go data processor, using seven planes of 19x19 values to represent the position of
... | [
"max.pumperla@googlemail.com"
] | max.pumperla@googlemail.com |
e42f78d219dc229a17fb5870bdb01f72df7e0996 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03105/s666582429.py | ab016687c44a5c29f7baead18b3f59c2b7730337 | [] | no_license | Aasthaengg/IBMdataset | 7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901 | f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8 | refs/heads/main | 2023-04-22T10:22:44.763102 | 2021-05-13T17:27:22 | 2021-05-13T17:27:22 | 367,112,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 815 | py | #from statistics import median
#import collections
#aa = collections.Counter(a) # list to list || .most_common(2)で最大の2個とりだせるお a[0][0]
from fractions import gcd
from itertools import combinations,permutations,accumulate, product # (string,3) 3回
#from collections import deque
from collections import deque,defaultdict,Cou... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
50de8f8f99b8bc3466cf24ce85afa5ad4e51cfdb | e232de1f42a922dc0c94d889c1f72d4f66b325d6 | /genfiles/proto/rec/gui/proto/Resizer_pb2.py | 065e69fbf5842f8fa39226a86cfa8d2e31a3ed35 | [] | no_license | rec/slow_gold | b19fcd684e469978bf20cd0638fa83786fc5ffae | f4551785cf7f9cf45605a850d013eef5d80f4ea6 | refs/heads/master | 2022-10-20T06:37:00.370927 | 2017-02-04T11:39:59 | 2017-02-04T11:39:59 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | true | 1,563 | py | # Generated by the protocol buffer compiler. DO NOT EDIT!
# source: rec/gui/proto/Resizer.proto
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.protobuf import reflection as _reflection
from google.protobuf import descriptor_pb2
# @@protoc_insertion_po... | [
"tom@swirly.com"
] | tom@swirly.com |
4203d1a854a8dd37fdb9eda8a1e7cac35ecb4cee | b162de01d1ca9a8a2a720e877961a3c85c9a1c1c | /165.compare-version-numbers.python3.py | 87a07d78743ccbd88f763f85f7771909751a5969 | [] | no_license | richnakasato/lc | 91d5ff40a1a3970856c76c1a53d7b21d88a3429c | f55a2decefcf075914ead4d9649d514209d17a34 | refs/heads/master | 2023-01-19T09:55:08.040324 | 2020-11-19T03:13:51 | 2020-11-19T03:13:51 | 114,937,686 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,153 | py | #
# [165] Compare Version Numbers
#
# https://leetcode.com/problems/compare-version-numbers/description/
#
# algorithms
# Medium (22.00%)
# Total Accepted: 118.9K
# Total Submissions: 540.6K
# Testcase Example: '"0.1"\n"1.1"'
#
# Compare two version numbers version1 and version2.
# If version1 > version2 return 1; ... | [
"richnakasato@hotmail.com"
] | richnakasato@hotmail.com |
a4a2d2dbd4a2b79ce6744d1e9304e8b3b5400cee | 1bed2f766620acf085ed2d7fd3e354a3482b8960 | /tests/components/roku/test_select.py | 003487c0adfdf8e753fab56230179045e1c451c3 | [
"Apache-2.0"
] | permissive | elupus/home-assistant | 5cbb79a2f25a2938a69f3988534486c269b77643 | 564150169bfc69efdfeda25a99d803441f3a4b10 | refs/heads/dev | 2023-08-28T16:36:04.304864 | 2022-09-16T06:35:12 | 2022-09-16T06:35:12 | 114,460,522 | 2 | 2 | Apache-2.0 | 2023-02-22T06:14:54 | 2017-12-16T12:50:55 | Python | UTF-8 | Python | false | false | 7,752 | py | """Tests for the Roku select platform."""
from unittest.mock import MagicMock
import pytest
from rokuecp import (
Application,
Device as RokuDevice,
RokuConnectionError,
RokuConnectionTimeoutError,
RokuError,
)
from homeassistant.components.roku.const import DOMAIN
from homeassistant.components.ro... | [
"noreply@github.com"
] | elupus.noreply@github.com |
822862f3f180bee1dd9909c9182fcf3e328eaab8 | bfe6c95fa8a2aae3c3998bd59555583fed72900a | /longestObstacleCourseAtEachPosition.py | 0ca0dd3396e0d71e0b4f329dc296a161e89b0e39 | [] | no_license | zzz136454872/leetcode | f9534016388a1ba010599f4771c08a55748694b2 | b5ea6c21bff317884bdb3d7e873aa159b8c30215 | refs/heads/master | 2023-09-01T17:26:57.624117 | 2023-08-29T03:18:56 | 2023-08-29T03:18:56 | 240,464,565 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 826 | py | from typing import List
class Solution:
def longestObstacleCourseAtEachPosition(self,
obstacles: List[int]) -> List[int]:
d = [obstacles[0]]
res = [1]
for ob in obstacles[1:]:
if ob >= d[-1]:
d.append(ob)
... | [
"zzz136454872@163.com"
] | zzz136454872@163.com |
b7987901a5a75205f490089306580edb93381290 | d579fdffa059724aff5a540e1ca6c12f508fd7b4 | /flex/django/ussd/screens/__init__.py | 4dafb9db0d2438990b3d4bade50a804a1be4d3ba | [
"MIT"
] | permissive | centergy/flex_ussd | 7493afddeea7c142e6ae6ee9f85406e165e65404 | ddc0ccd192e3a0a82e8b7705f088862d59656c28 | refs/heads/master | 2020-03-24T21:21:46.790958 | 2018-09-23T01:07:13 | 2018-09-23T01:07:13 | 143,027,887 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 186 | py | from .base import UssdScreenType, UssdScreen, UssdPayload, ScreenState, ScreenRef
from .base import get_screen, get_screen_uid, get_home_screen, render_screen
from .base import END, CON
| [
"davidmkyalo@gmail.com"
] | davidmkyalo@gmail.com |
887b1ddeae86361e13fc5082defd58656ea36555 | f71ee969fa331560b6a30538d66a5de207e03364 | /scripts/client/messenger/gui/scaleform/channels/bw_factories.py | 35ded875a0efc378793bae087ca90f289d31b095 | [] | no_license | webiumsk/WOT-0.9.8-CT | 31356ed01cb110e052ba568e18cb2145d4594c34 | aa8426af68d01ee7a66c030172bd12d8ca4d7d96 | refs/heads/master | 2016-08-03T17:54:51.752169 | 2015-05-12T14:26:00 | 2015-05-12T14:26:00 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,259 | py | # Embedded file name: scripts/client/messenger/gui/Scaleform/channels/bw_factories.py
import chat_shared
from constants import PREBATTLE_TYPE
from debug_utils import LOG_ERROR
from messenger.gui.Scaleform.channels import bw_lobby_controllers
from messenger.gui.Scaleform.channels import bw_battle_controllers
from messen... | [
"info@webium.sk"
] | info@webium.sk |
4b7fa0b89034a3c73e7c53685b6db1d8756161b3 | 54f352a242a8ad6ff5516703e91da61e08d9a9e6 | /Source Codes/CodeJamData/13/21/1.py | 3c669ac25e4a3e7827b4a913749aefc3eec998b5 | [] | no_license | Kawser-nerd/CLCDSA | 5cbd8a4c3f65173e4e8e0d7ed845574c4770c3eb | aee32551795763b54acb26856ab239370cac4e75 | refs/heads/master | 2022-02-09T11:08:56.588303 | 2022-01-26T18:53:40 | 2022-01-26T18:53:40 | 211,783,197 | 23 | 9 | null | null | null | null | UTF-8 | Python | false | false | 651 | py | def solvable(A, motes, adds):
for m in motes:
while m >= A and adds > 0:
A += A - 1
adds -= 1
if m >= A:
return False
A += m
return True
def solve_case(test_case):
A, N = map(int, raw_input().split())
motes = sorted(map(int, raw_input().spl... | [
"kwnafi@yahoo.com"
] | kwnafi@yahoo.com |
d35cc85e0174d8db3ca2cc290807848677c9a764 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_325/ch21_2020_03_02_20_41_04_179689.py | 7debae918cd7832c89f016bfcd18e1ac314c922c | [] | no_license | gabriellaec/desoft-analise-exercicios | b77c6999424c5ce7e44086a12589a0ad43d6adca | 01940ab0897aa6005764fc220b900e4d6161d36b | refs/heads/main | 2023-01-31T17:19:42.050628 | 2020-12-16T05:21:31 | 2020-12-16T05:21:31 | 306,735,108 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 277 | py | x = int(input("quantos dias "))
y = int(input("quantas horas "))
z = int(input("quantos minutos "))
w = int(input("quantos segundos "))
def soma(dias,horas,minutos,segundos):
d = 86400*dias
h = 3600*horas
m = 60*minutos
s = segundos
c = d+h+m+s
return c | [
"you@example.com"
] | you@example.com |
a05fd43c86e27b01c3f109a88d01540a3b937ad3 | e52765058c96b2123aacf690204d8583a90ad145 | /book_figures/chapter1/fig_dr7_quasar.py | d8d68ebc0777cb56647e6aefdfbe601cda1ee2ea | [
"BSD-3-Clause",
"BSD-2-Clause"
] | permissive | astrofanlee/astroML | dcecb1dbc40dcf8c47deeb11230cff62a451e3c9 | acb02f4385049e7a09ee5eab6f1686e7f119b066 | refs/heads/master | 2020-12-29T03:30:56.700274 | 2013-03-04T16:49:40 | 2013-03-04T16:49:40 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,022 | py | """
SDSS DR7 Quasars
----------------
This example shows how to fetch the SDSS quasar photometric data, and to
plot the relationship between redshift and color.
"""
# Author: Jake VanderPlas <vanderplas@astro.washington.edu>
# License: BSD
# The figure produced by this code is published in the textbook
# "Statistic... | [
"vanderplas@astro.washington.edu"
] | vanderplas@astro.washington.edu |
fd496e277fdefb2a2c9b541c99a63156f780d0f2 | 67640d102dbf68c635fdcbac4ae16e91b327e684 | /demo01_test/test_cases/__init__.py | eea3614887f048b7f90597b92be325518e4f6032 | [] | no_license | B9527/unittest_demo | f2ba28fdda309731f0a925732a06ea9824ec03ce | d93846d3497c8bad66f34796b96d014093cd60b7 | refs/heads/master | 2021-01-21T17:10:35.242416 | 2017-07-28T02:42:13 | 2017-07-28T02:42:13 | 98,510,977 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 278 | py | #!/usr/bin/env python
# -*- coding:utf-8 -*-
"""
#----------------------------------------------
# Copyright (python)
# FileName: __init__.py
# Version: 0.0.2
# Author : baiyang
# LastChange: 2017/7/27 15:19
# Desc:
# History:
#--------------------------------------------
""" | [
"1335239218@qq.com"
] | 1335239218@qq.com |
3e83a4254bd9cd516265553423831b535c48d256 | d62028695590b6c52cbc71af1dde6e7fdecb3f9b | /FALCON/src/utils/default_param.py | 7314c5af350c0464df65e30c7b8c8930b80db20d | [
"Apache-2.0"
] | permissive | zijiantang168/Reproducability-FALCON | 3cf0ed46ddf9df414fcf1baf5adb0a9c42111273 | eef9d8d72ae3b763d6a88107b90db9533afedd9e | refs/heads/master | 2023-04-20T11:07:40.587829 | 2021-05-13T14:04:32 | 2021-05-13T14:04:32 | 367,063,997 | 0 | 0 | Apache-2.0 | 2021-05-13T13:52:37 | 2021-05-13T13:52:37 | null | UTF-8 | Python | false | false | 5,163 | py | """
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this ... | [
"none@none.com"
] | none@none.com |
09906cf7bda1b80f0d3b583f2413572b3f3fcd22 | ab19b1e637109f6a6f32e99714ea1c7cbe1d5ec0 | /articles/migrations/0019_article_publish_after.py | a9d38592c2a964ef44a79aeec0ecba6e0d1db057 | [] | no_license | devonwarren/totemag | daf05876cfe636c4dcfe83b764900a0bc4c9c29d | 304ab0e2f72b926e63de706a6e3dc0b043db36fd | refs/heads/master | 2021-01-17T20:48:48.671352 | 2016-06-02T00:57:11 | 2016-06-02T00:57:11 | 58,146,953 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 538 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.9.2 on 2016-02-18 22:41
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('articles', '0018_auto_20151124_2026'),
]
operations = [
migrations.AddField(... | [
"devon.warren@gmail.com"
] | devon.warren@gmail.com |
f993e3b5fb115450f780e5412a64f240b4667778 | 9e7d7b4d029554eed0f760a027cd94558b919ae2 | /chapter2/continue_break_statements.py | e9af6c8a148f493882b7cecd565d9844fcdfc65c | [] | no_license | pooja1506/AutomateTheBoringStuff_2e | 8247b68a195d5e1976c6474f0e97d947906ffd35 | 5bab9ccdcdb22ee10fe1272c91042be40fd67c17 | refs/heads/master | 2022-04-10T19:21:44.402829 | 2020-04-05T12:10:32 | 2020-04-05T12:10:32 | 249,620,282 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 427 | py | while True:
print("who are you?")
name = input()
if name != 'Joe':
continue
print("hello joe , please enter your password")
password = input()
if password == 'Seasword':
break
print("access granted")
#continue statement is used to jump back to the start of the loop to ... | [
"pooja.dmehta15@gmail.com"
] | pooja.dmehta15@gmail.com |
901b1b56c55239bb850491d05e8b6501220bd9f6 | 7cf119239091001cbe687f73018dc6a58b5b1333 | /datashufflepy-zeus/src/branch_scripts2/NEWS/ZX_CJXW_ZYCJ/ZX_CJXW_ZYCJ_JJW_CJZQ.py | bb53ef4acf7a8bb3b4a7661eb8cf6b64186458af | [
"Apache-2.0"
] | permissive | ILKKAI/dataETL | 0f5b80c3482994f735f092a1e01fa1009bac4109 | 32f7ec3aaaf32b5074536a615cb9cd5c28bd499c | refs/heads/master | 2022-04-04T19:27:05.747852 | 2020-02-28T11:17:48 | 2020-02-28T11:17:48 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 358 | py | # -*- coding: utf-8 -*-
from database._mongodb import MongoClient
def data_shuffle(data):
return data
if __name__ == '__main__':
main_mongo = MongoClient(entity_code="ZX_CJXW_ZYCJ_JJW_CJZQ", mongo_collection="ZX_CJXW_ZYCJ")
data_list = main_mongo.main()
for data in data_list:
re_data = data... | [
"499413642@qq.com"
] | 499413642@qq.com |
e6bdd6de0cabea72e54e64e2694a3cd452cc4fa4 | bad6970aa7c929bcd8447106c1f3af6567a42456 | /tests/test_snowflake.py | 70f14b17835adcae044d93f7c7c15fc290185db5 | [
"MIT"
] | permissive | wrodney/simple-ddl-parser | ad498221367bf657ed94106feded5ff8c3fdb46b | 6e4d1d65f74fa2f9266a4f9e28bd8b6e42ddaa14 | refs/heads/main | 2023-08-15T01:26:48.214664 | 2021-09-22T06:20:11 | 2021-09-22T06:20:11 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,073 | py | from simple_ddl_parser import DDLParser
def test_clone_db():
ddl = """
create database mytestdb_clone clone mytestdb;
"""
result = DDLParser(ddl).run(group_by_type=True)
expected = {
"databases": [
{"clone": {"from": "mytestdb"}, "database_name": "mytestdb_clone"}
],
... | [
"xnuinside@gmail.com"
] | xnuinside@gmail.com |
85d28b2ed8514cc96ce157349b50199f1c467e84 | 39f37b192565bf0a30252099a0310d0394b5cb2c | /deepsearch/cps/apis/public/models/annotated_text.py | 2e9d8b1de43c2ba2f27f3f35027cb62caa3a2b3a | [
"MIT"
] | permissive | DS4SD/deepsearch-toolkit | 5a6608b744bcf2d7da5106ece735691ee10f79fb | 20d8198db6d5a75cfe374060910a0375312dadef | refs/heads/main | 2023-08-04T14:17:21.345813 | 2023-07-28T11:51:18 | 2023-07-28T11:51:18 | 498,645,500 | 88 | 13 | MIT | 2023-09-07T15:17:29 | 2022-06-01T08:05:41 | Python | UTF-8 | Python | false | false | 6,220 | py | # coding: utf-8
"""
Corpus Processing Service (CPS) API
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501
The version of the OpenAPI document: 2.0.0
Generated by: https://openapi-generator.tech
"""
import pprint
import re # noq... | [
"dol@zurich.ibm.com"
] | dol@zurich.ibm.com |
b6136bca21599639df960e68a3941f35468a6848 | 67f36de3eec7f64b4b1070727ab7bc34e38d3724 | /apps/users/migrations/0002_usersdesc.py | 18e5cba06a0ea729d80fe2f82125dfdd954abab7 | [] | no_license | shd0812/django_shd_restframework | a46371756accffddfe3e915dc22f96f0bc2f0740 | d6ab9c2896b0e3766e17983019d2ac09a8c81b99 | refs/heads/main | 2023-01-19T11:17:19.097711 | 2020-11-22T11:25:05 | 2020-11-22T11:25:05 | 315,007,491 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 874 | py | # Generated by Django 3.1.2 on 2020-11-15 04:05
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('users', '0001_initial'),
]
operations = [
migrations.CreateModel(
name='UsersDesc',
... | [
"759275499@qq.com"
] | 759275499@qq.com |
bf4b2947db1bed8d4e6c36d47effa7e96ffa5242 | ded13e921c8365c6113911a5834969ec3d33f989 | /063/Unique Paths II.py | a082d0d5a27c38b339744a82a15a7aaff03aecc0 | [] | no_license | ArrayZoneYour/LeetCode | b7b785ef0907640623e5ab8eec1b8b0a9d0024d8 | d09f56d4fef859ca4749dc753d869828f5de901f | refs/heads/master | 2021-04-26T23:03:10.026205 | 2018-05-09T15:49:08 | 2018-05-09T15:49:08 | 123,922,098 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 991 | py | # /usr/bin/python
# coding: utf-8
class Solution:
def uniquePathsWithObstacles(self, obstacleGrid):
"""
:type obstacleGrid: List[List[int]]
:rtype: int
"""
height = len(obstacleGrid)
width = len(obstacleGrid[0])
step_num = [[0 for col in range(width)] for ro... | [
"hustliyidong@gmail.com"
] | hustliyidong@gmail.com |
5b2b9ffdd1e257920851c47cf8527bcd03b9c247 | 0b134572e3ac3903ebb44df6d4138cbab9d3327c | /app/grandchallenge/workstation_configs/migrations/0008_auto_20210920_1439.py | a5c71b249716b80883be22b6699341c64c3c59fb | [
"Apache-2.0"
] | permissive | comic/grand-challenge.org | 660de3bafaf8f4560317f1dfd9ae9585ec272896 | dac25f93b395974b32ba2a8a5f9e19b84b49e09d | refs/heads/main | 2023-09-01T15:57:14.790244 | 2023-08-31T14:23:04 | 2023-08-31T14:23:04 | 4,557,968 | 135 | 53 | Apache-2.0 | 2023-09-14T13:41:03 | 2012-06-05T09:26:39 | Python | UTF-8 | Python | false | false | 1,446 | py | # Generated by Django 3.1.13 on 2021-09-20 14:39
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
(
"workstation_configs",
"0007_workstationconfig_auto_jump_center_of_gravity",
)
]
operations = [
migrations.... | [
"noreply@github.com"
] | comic.noreply@github.com |
d12a3c1a0a1d4a430b8fb15efcaa15d9f558aec6 | 892ab4d7836e369d0e657be91b4dcd3e8153f372 | /compute/wps/tests/test_tasks_edas.py | 34133d825a836e498dd903b6530238665d2e93a4 | [] | no_license | davidcaron/esgf-compute-wps | 9e28e3af1ec1f524abdcce39cfe42c7bbcb3d50b | c3ffca449f65f8d206032d040ead6e14085f04ab | refs/heads/master | 2020-04-16T20:54:59.095653 | 2018-05-04T22:00:45 | 2018-05-04T22:00:45 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,793 | py | import os
import shutil
import cwt
import mock
from django import test
from . import helpers
from wps import models
from wps import settings
from wps import WPSError
from wps.tasks import cdat
from wps.tasks import edas
class EDASTaskTestCase(test.TestCase):
fixtures = ['processes.json', 'servers.json', 'users.j... | [
"boutte.jason@gmail.com"
] | boutte.jason@gmail.com |
8fd790caf96a76d675989b45a6882cf5d8639859 | 824a58f05b24ef9ec0920aa046498c816f5c5121 | /models.py | 39fe32464103cff49911ac03919aff948c927db7 | [] | no_license | zhakguder/adversarial-generation | c383e4338b53e3763ccbf572644ff8261d717ea6 | 10d2eb64f1b6a9117d86f3333a236c25b399dd3a | refs/heads/master | 2020-05-17T16:40:50.319921 | 2019-05-21T14:25:50 | 2019-05-21T14:25:50 | 183,825,906 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,985 | py | from functools import partial
import tensorflow as tf
from tensorflow import keras
from tensorflow.keras import Sequential
from tensorflow.keras.layers import Dense, Flatten
from utils import _softplus_inverse
import tensorflow_probability as tfp
from custom_layers import LSHLayer, clusterLayer
from settings import get... | [
"zeynep.hakguder@huskers.unl.edu"
] | zeynep.hakguder@huskers.unl.edu |
2528570aad7cb0dbdf5b4fe262b0745d0d60e920 | ecb4eb32a75e626ebee29142fa0b28e18362dd8c | /adam/domain/document_item.py | c3eb014f1ffdab1b17baccbf0ead952880b7b1d3 | [
"BSD-3-Clause"
] | permissive | souzaux/adam | a2e29d210ccfbf8eb02a5f1a1dc5be297515fdc3 | cbb261b909adde39b874d355c47fe3824cd3e9e1 | refs/heads/master | 2020-05-30T13:25:55.290349 | 2016-08-04T09:22:12 | 2016-08-04T09:22:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,726 | py | # -*- coding: utf-8 -*-
"""
adam.domain.document_item.py
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
'document_item' schema settings.
:copyright: (c) 2016 by Nicola Iarocci and CIR2000.
:license: BSD, see LICENSE for more details.
"""
from common import variation
from vat import vat_field
from warehouses import ... | [
"nicola@nicolaiarocci.com"
] | nicola@nicolaiarocci.com |
b9ada5a859b6f7ba9697a4b51f1a7f8c32c8c74f | e976eb4db57ddee4947cbab8746446dd53f6cf6f | /1-50/与所有单词相关联的字串.py | 745ac8d7d7a3e650d68f9b5975bee5c1a37da875 | [] | no_license | Aiyane/aiyane-LeetCode | 5328529079bcfbc84f4e4d67e3d8736b9745dc0d | 3c4d5aacc33f3ed66b6294894a767862170fb4f6 | refs/heads/master | 2020-04-01T20:33:54.125654 | 2019-06-25T09:56:10 | 2019-06-25T09:56:10 | 153,610,015 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,974 | py | #!/usr/bin/env/python3
# -*- coding: utf-8 -*-
# 与所有单词相关联的字串.py
"""
给定一个字符串 s 和一些长度相同的单词 words。在 s 中找出可以恰好串联 words 中所有单词的子串的起始位置。
注意子串要与 words 中的单词完全匹配,中间不能有其他字符,但不需要考虑 words 中单词串联的顺序。
示例 1:
输入:
s = "barfooothefooobarman",
words = ["fooo","bar"]
输出: [0,9]
解释: 从索引 0 和 9 开始的子串分别是 "barfoor" 和 "foobar" 。
输出的顺序不重要, [... | [
"2310091880qq@gmail.com"
] | 2310091880qq@gmail.com |
3569013ca6cef03a594258fb5f91a3563d856154 | 801f367bd19b8f2ab08669fd0a85aad7ace961ac | /cleaned_version/_train_utils/utils.py | b830833f01ab67eaec0665e6da7d821dc5b770b1 | [
"MIT"
] | permissive | Wendong-Huo/thesis-bodies | d91b694a6b1b6a911476573ed1ed27eb27fb000d | dceb8a36efd2cefc611f6749a52b56b9d3572f7a | refs/heads/main | 2023-04-17T18:32:38.541537 | 2021-03-12T19:53:23 | 2021-03-12T19:53:23 | 623,471,326 | 1 | 0 | null | 2023-04-04T12:45:48 | 2023-04-04T12:45:47 | null | UTF-8 | Python | false | false | 6,053 | py | import glob
import os
import gym
from stable_baselines3 import A2C, DDPG, DQN, HER, PPO, SAC, TD3
from stable_baselines3.common.monitor import Monitor
from stable_baselines3.common.vec_env import DummyVecEnv, VecNormalize
from stable_baselines3.common.utils import set_random_seed
from stable_baselines3.common.callbacks... | [
"sliu1@uvm.edu"
] | sliu1@uvm.edu |
065d7e8d210b3c6e4e6c55a6995e288bbd83b8c6 | fe0017ae33385d7a2857d0aa39fa8861b40c8a88 | /env/lib/python3.8/site-packages/sklearn/mixture/base.py | 1daf2061f2fd01b8a342289d9497009a817083cd | [] | no_license | enriquemoncerrat/frasesback | eec60cc7f078f9d24d155713ca8aa86f401c61bf | e2c77f839c77f54e08a2f0930880cf423e66165b | refs/heads/main | 2023-01-03T23:21:05.968846 | 2020-10-18T21:20:27 | 2020-10-18T21:20:27 | 305,198,286 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 556 | py |
# THIS FILE WAS AUTOMATICALLY GENERATED BY deprecated_modules.py
import sys
# mypy error: Module X has no attribute y (typically for C extensions)
from . import _base # type: ignore
from ..externals._pep562 import Pep562
from ..utils.deprecation import _raise_dep_warning_if_not_pytest
deprecated_path = 'sklearn.mix... | [
"enriquemoncerrat@gmail.com"
] | enriquemoncerrat@gmail.com |
282b16e40ec888666211472ca10dba0e709687b1 | 81fe7f2faea91785ee13cb0297ef9228d832be93 | /HackerRank/Contests/WeekOfCode21/kangaroo.py | 0ba85ccd8448b9b12f2e0718b459aa938a331f45 | [] | no_license | blegloannec/CodeProblems | 92349c36e1a35cfc1c48206943d9c2686ea526f8 | 77fd0fa1f1a519d4d55265b9a7abf12f1bd7d19e | refs/heads/master | 2022-05-16T20:20:40.578760 | 2021-12-30T11:10:25 | 2022-04-22T08:11:07 | 54,330,243 | 5 | 1 | null | null | null | null | UTF-8 | Python | false | false | 283 | py | #!/usr/bin/env python
import sys
def main():
x1,v1,x2,v2 = map(int,sys.stdin.readline().split())
if x1==x2:
print 'YES'
elif v1==v2:
print 'NO'
elif (x1-x2)*(v2-v1)>=0 and (x1-x2)%(v2-v1)==0:
print 'YES'
else:
print 'NO'
main()
| [
"blg@gmx.com"
] | blg@gmx.com |
8d1ae47c9f07f66017f56445147ce843cb789c27 | 504a5e7c9319bda04e3d33978f64404bba47392a | /Python 200/034.py | 4afcfdef5e71d2866eeb60876b0ee093ce0122a4 | [] | no_license | Ani-Gil/Python | 9fd02d321a7e21c07ea5fa30ae0f0336cae15861 | 5bb019bfbe19f10f20f6c5883299011717d20f55 | refs/heads/main | 2023-03-15T02:21:07.467329 | 2021-02-24T01:20:00 | 2021-02-24T01:20:00 | 324,080,371 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 383 | py | # 034.py - 문자열 포맷팅 이해하기
txt1 = '자바'; txt2 = '파이썬'
num1 = 5; num2 = 10
print('나는 %s보다 %s에 더 익숙합니다.' % (txt1, txt2))
print('%s은 %s보다 %d배 더 쉽습니다.' % (txt2, txt1, num1))
print('%d + %d + %d' % (num1, num2, num1 + num2))
print('작년 세계 경제 성장률은 전년에 비해 %d%% 포인트 증가했다.' % num1)
| [
"dlatldn426@gmail.com"
] | dlatldn426@gmail.com |
8ff9155fca196073894615de07c53e2ea89d6b7b | 364b36d699d0a6b5ddeb43ecc6f1123fde4eb051 | /_downloads_1ed/fig_lyndenbell_toy.py | 80a9743fd39ab85865499aac101b2c96c46b7eaf | [] | no_license | astroML/astroml.github.com | eae3bfd93ee2f8bc8b5129e98dadf815310ee0ca | 70f96d04dfabcd5528978b69c217d3a9a8bc370b | refs/heads/master | 2022-02-27T15:31:29.560052 | 2022-02-08T21:00:35 | 2022-02-08T21:00:35 | 5,871,703 | 2 | 5 | null | 2022-02-08T21:00:36 | 2012-09-19T12:55:23 | HTML | UTF-8 | Python | false | false | 4,082 | py | """
Luminosity function code on toy data
------------------------------------
Figure 4.9.
An example of using Lynden-Bell's C- method to estimate a bivariate
distribution from a truncated sample. The lines in the left panel show the true
one-dimensional distributions of x and y (truncated Gaussian distributions).
The ... | [
"vanderplas@astro.washington.edu"
] | vanderplas@astro.washington.edu |
29c37a9dfe43e6415a3d457fbea720baf1e1e1d2 | dfcb9827b966a5055a47e27b884eaacd88269eb1 | /ssseg/cfgs/ce2p/cfgs_voc_resnet101os8.py | 385c6008fa55db823a508dafaaef19402fd531a9 | [
"MIT"
] | permissive | RiDang/sssegmentation | cdff2be603fc709c1d03897383032e69f850f0cd | 2a79959a3d7dff346bab9d8e917889aa5621615a | refs/heads/main | 2023-02-05T12:52:35.391061 | 2020-12-27T05:59:58 | 2020-12-27T05:59:58 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,380 | py | '''define the config file for voc and resnet101os8'''
from .base_cfg import *
# modify dataset config
DATASET_CFG = DATASET_CFG.copy()
DATASET_CFG['train'].update(
{
'type': 'voc',
'set': 'trainaug',
'rootdir': 'data/VOCdevkit/VOC2012',
}
)
DATASET_CFG['test'].update(
{
'ty... | [
"1159254961@qq.com"
] | 1159254961@qq.com |
b7eb6dfe9463dbbb7e94e66dc97dd8fd8e80d49b | 0809673304fe85a163898983c2cb4a0238b2456e | /src/lesson_algorithms/contextlib_exitstack_callbacks_error.py | ce142be2225b3d9e9678f796d9a6bd379eda226d | [
"Apache-2.0"
] | permissive | jasonwee/asus-rt-n14uhp-mrtg | 244092292c94ff3382f88f6a385dae2aa6e4b1e1 | 4fa96c3406e32ea6631ce447db6d19d70b2cd061 | refs/heads/master | 2022-12-13T18:49:02.908213 | 2018-10-05T02:16:41 | 2018-10-05T02:16:41 | 25,589,776 | 3 | 1 | Apache-2.0 | 2022-11-27T04:03:06 | 2014-10-22T15:42:28 | Python | UTF-8 | Python | false | false | 356 | py | import contextlib
def callback(*args, **kwds):
print('closing callback({}, {})'.format(args, kwds))
try:
with contextlib.ExitStack() as stack:
stack.callback(callback, 'arg1', 'arg2')
stack.callback(callback, arg3='val3')
raise RuntimeError('thrown error')
except RuntimeError as err:... | [
"peichieh@gmail.com"
] | peichieh@gmail.com |
3549ee4210441cea0700fff60b1ab8ff44b03cf8 | 86cc17a69213569af670faed7ad531cb599b960d | /prooo26.py | 19af9019514aa873268da93a2c03efbcc42129c0 | [] | no_license | LakshmikanthRavi/guvi-lux | ed1c389e27a9ec62e0fd75c140322563f68d311a | 5c29f73903aa9adb6484c76103edf18ac165259e | refs/heads/master | 2020-04-15T05:07:19.743874 | 2019-08-13T08:53:00 | 2019-08-13T08:53:00 | 164,409,489 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 301 | py | z1=int(input())
l=list(map(int,input().split()))
p=[]
t=[]
u=[]
o=[]
for i in range(0,len(l)+1):
for j in range(0,len(l)+1):
p.append(l[i:j])
for i in p:
if i!=[]:
t.append(i)
for i in t:
if sorted(i)==i:
u.append(i)
for i in u:
o.append(len(i))
print(max(o))
| [
"noreply@github.com"
] | LakshmikanthRavi.noreply@github.com |
02a0734050ac0604dbf68fd0310300efecd5d176 | 780ab93e6c6871673ae667c9a180892bd3073f56 | /app/__init__.py | 073ff3e32cc176e023d0c1fa0460e64bcd462e67 | [] | no_license | changbj00/ApiTestManage | d6a8d030289455555a0ed460ed880081da08b4bf | c2fd19c54100acf72ce61bf920dadeae5a34f747 | refs/heads/master | 2020-04-01T00:15:11.097011 | 2018-09-30T09:41:30 | 2018-09-30T09:41:30 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,083 | py | # encoding: utf-8
import os
from flask import Flask
from flask_sqlalchemy import SQLAlchemy
from flask_moment import Moment
from flask_login import LoginManager
from config import config
from config import config_log
from config import ConfigTask
from .util import global_variable # 初始化文件地址
login_manager = LoginManage... | [
"362508572@qq.com"
] | 362508572@qq.com |
e709360b59b2c74ebfaf4a1c0ea08606f4413773 | 590a68b6e68b41b6b9f8d8f5240df3181af0b07f | /RNN/test/dataloader_frames_p2.py | bf4661febeea33d94a2b6ba2ae72bb83bd3f9d6e | [] | no_license | ziqinXU/RNN-Video-Segmentation | e1a3098f5597960f57a1626c2cec08ad5f6635b0 | 0baa348fd08fa7f6813cd55e70004b96c559b46a | refs/heads/master | 2022-04-04T10:51:44.583855 | 2020-02-06T07:14:49 | 2020-02-06T07:14:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,396 | py | import os
import pickle as pk
import reader
import numpy as np
import sys
import torch
import torchvision.transforms as transforms
from torch.utils.data import Dataset
from generate_frames_p2 import extract_frames
MEAN = [0.485, 0.456, 0.406]
STD = [0.229, 0.224, 0.225]
class DATA(Dataset):
def __init__(self, ... | [
"noreply@github.com"
] | ziqinXU.noreply@github.com |
78765e98d7aca64c1627f12e61159fa84b27b105 | 1287bbb696e240dd0b92d56d4fdf4246370f3e14 | /_requests.py | d8a233f7f9ee5c53302d0f30e1a99ef3ed08382e | [] | no_license | omerfarukcelenk/PythonCalismalari | ed0c204084860fddcb892e6edad84fdbc1ed38ec | 28da12d7d042ec306f064fb1cc3a1a026cb57b74 | refs/heads/main | 2023-04-13T18:23:15.270020 | 2021-04-26T21:06:21 | 2021-04-26T21:06:21 | 361,893,918 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 236 | py | import requests
import json
result = requests.get("https://jsonplaceholder.typicode.com/todos")
result = json.loads(result.text)
print(result[0]["title"])
print(result[0])
for i in result:
print(i["title"])
print(type(result))
| [
"omerfar0133@gmail.com"
] | omerfar0133@gmail.com |
81fd332f532043398a89498afa06b89ca560e631 | 944a91cbdb75e53e3de22604b258d2404bc7415d | /jobs/urls.py | 5848eb07e3640a5b1574e0abbc5be4e7e4dcadbd | [] | no_license | lopezjronald/django-finance-project | 3662adbe406071b7a07ab36c9592ac194f5e91ea | a49667f2c4b4b0350d0322a4def49803c3b19c15 | refs/heads/master | 2022-12-25T00:11:22.905175 | 2020-09-29T15:45:20 | 2020-09-29T15:45:20 | 293,967,619 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 216 | py | from django.urls import path
from .views import JobListView, JobDetailView
urlpatterns = [
path('', JobListView.as_view(), name='job_list'),
path('<uuid:pk>/', JobDetailView.as_view(), name='job_detail'),
]
| [
"lopez.j.ronald@gmail.com"
] | lopez.j.ronald@gmail.com |
6522b74111249a279635c042c7be80a569507cc3 | 30a8b69bd2e0a3f3c2c1c88fb3bd8a28e6fc4cd0 | /Part1/auth_uri_foursquare.py | b637f4a2e5e5fcb20022842e6ea6f0ce4918dfb4 | [] | no_license | llord1/Mining-Georeferenced-Data | d49108f443922f02b90431ad7a9626ea17fd0554 | c71f2e151ccfc4a1a9c07b5fcf4e95b7f7ba70e9 | refs/heads/master | 2021-05-30T13:27:57.663015 | 2015-12-29T09:10:08 | 2015-12-29T09:10:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 525 | py | #!/usr/bin/env python
import foursquare
accounts = {"tutorial": {"client_id": "CLIENT_ID",
"client_secret": "CLIENT_SECRET",
"access_token": ""
}
}
app = accounts["tutorial"]
client = foursquare.Foursquare(client_id=app["client_i... | [
"bgoncalves@gmail.com"
] | bgoncalves@gmail.com |
1dc1981e9a043f4565683d175e6c60902db0a53b | 899aeab7e2594964ee57f60b127db6913b755342 | /src/importlinter/__init__.py | 96d6ea30852d12e3ccae4a0c89ba08aec3e76e6d | [
"BSD-3-Clause",
"BSD-2-Clause"
] | permissive | skarzi/import-linter | c8b41a7828d3dc3970c63612fee0f5687d93be17 | 1ac62d58575235ada887e594819ed294c1b1d2b2 | refs/heads/master | 2023-02-06T13:39:10.883308 | 2020-12-01T08:44:59 | 2020-12-01T08:44:59 | 264,639,120 | 0 | 0 | BSD-2-Clause | 2020-05-17T10:35:50 | 2020-05-17T10:35:49 | null | UTF-8 | Python | false | false | 157 | py | __version__ = "1.2"
from .application import output # noqa
from .domain import fields # noqa
from .domain.contract import Contract, ContractCheck # noqa
| [
"david.seddon@octoenergy.com"
] | david.seddon@octoenergy.com |
a67a06cb6603c817b9768586b740c9ac6d754f98 | f445450ac693b466ca20b42f1ac82071d32dd991 | /generated_tempdir_2019_09_15_163300/generated_part010168.py | 32165658309da40110f837edcd7c20bbc61d6fcc | [] | no_license | Upabjojr/rubi_generated | 76e43cbafe70b4e1516fb761cabd9e5257691374 | cd35e9e51722b04fb159ada3d5811d62a423e429 | refs/heads/master | 2020-07-25T17:26:19.227918 | 2019-09-15T15:41:48 | 2019-09-15T15:41:48 | 208,357,412 | 4 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,300 | py | from sympy.abc import *
from matchpy.matching.many_to_one import CommutativeMatcher
from matchpy import *
from matchpy.utils import VariableWithCount
from collections import deque
from multiset import Multiset
from sympy.integrals.rubi.constraints import *
from sympy.integrals.rubi.utility_function import *
from sympy.... | [
"franz.bonazzi@gmail.com"
] | franz.bonazzi@gmail.com |
52877fb16c62338f0a45f2d98d40f9cbdd981dd0 | 6fd3fff474656ff98dffb597fef249f156624856 | /footlbotest/leaveMsgUI/51xingsheng/leaveMsgUI004.py | 5c70ce57150203f53045a361e443f424c6167c47 | [] | no_license | lobo1233456/footlbotestproj | c241d426a5f186616cbdf68f1e093e0a56c4db33 | f69ea745f1a91f3f365007506c5e6d12cdc7dd8b | refs/heads/master | 2020-07-05T14:42:42.067328 | 2019-09-09T06:18:43 | 2019-09-09T06:18:43 | 202,675,044 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,870 | py | #!user/bin/env python3
# -*- coding: UTF-8 -*-
import random
import time
from retrying import retry
from selenium import webdriver
from selenium.common.exceptions import NoSuchElementException, NoAlertPresentException, ElementClickInterceptedException
from selenium.webdriver.support.select import Select
from footlbol... | [
"1009548820@qq.com"
] | 1009548820@qq.com |
1199f68eef14572d6f677aad8d14f4498c886919 | 8d3835e39cbc2c74d8535b809686d6ab3033c0d0 | /ecommerce/orders/migrations/0009_auto_20190123_2034.py | 3931948db21a8cd84cd407429a0528cf9f12ada5 | [] | no_license | gayatribasude/GayatrisWorld | 125698955cd8b98a5aa2377331293587a57f2911 | 552ea2ef946e95f5bccc4e51d4030484ab0bc438 | refs/heads/master | 2023-06-25T19:45:03.232059 | 2021-08-02T16:43:47 | 2021-08-02T16:43:47 | 384,343,617 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 505 | py | # Generated by Django 2.1.3 on 2019-01-23 15:04
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('orders', '0008_auto_20190123_1027'),
]
operations = [
migrations.AlterField(
model_name='order',
name='status',
... | [
"gayatribasude"
] | gayatribasude |
03d5e8af92c8ad4c1a8a5acf1d00dfb40be96012 | 390f1fd25ebce9e18bce582b7c0b81ab989ff738 | /npmctree/sampling.py | 1d27118bced607cdbcbaaf2cec4148654dd15a74 | [] | no_license | argriffing/npmctree | 439f1e94ff876dfa09e3ab21ec7691c44b67b813 | 274f022baca5a4d3d4e74392ce79934ff3d21c32 | refs/heads/master | 2016-09-11T08:12:33.662556 | 2014-09-15T19:13:08 | 2014-09-15T19:13:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,409 | py | """
Joint state sampling algorithm for a Markov chain on a NetworkX tree graph.
"""
from __future__ import division, print_function, absolute_import
import random
import numpy as np
import networkx as nx
from npmctree import dynamic_fset_lhood, dynamic_lmap_lhood
from .util import normalized, weighted_choice
__all... | [
"argriffi@ncsu.edu"
] | argriffi@ncsu.edu |
b0dd601df311767b266472a4fb9bae1c30625292 | f18ca41c7aaa1da62ade3fb12ff69c2de863bc5f | /server/workers/dataprocessing/run_dataprocessing.py | 7f299c873debe81d77d589105ffae658b93b4248 | [
"MIT"
] | permissive | chreman/Headstart | 983111e03db2e69406f3c6feb6387b0757c6b62d | 5d8b956faac4389c649f3072b5ac55aaa01644c6 | refs/heads/master | 2021-10-21T04:50:03.608480 | 2021-10-14T13:02:53 | 2021-10-14T13:02:53 | 20,580,403 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 571 | py | import os
import json
import redis
from dataprocessing.src.headstart import Dataprocessing
if __name__ == '__main__':
redis_config = {
"host": os.getenv("REDIS_HOST"),
"port": os.getenv("REDIS_PORT"),
"db": os.getenv("REDIS_DB"),
"password": os.getenv("REDIS_PASSWORD")
}
r... | [
"web@christopherkittel.eu"
] | web@christopherkittel.eu |
7025db40f2f96e1a274d3040dac948135d57aefc | 043e511436798e9aed96052baddac7a353ac6562 | /paintHouse.py | b1ca2afe5bc36ee0ad4dad8eecab0186121c949e | [] | no_license | bch6179/Pyn | 01e19f262cda6f7ee1627d41a829609bde153a93 | e718fcb6b83664d3d6413cf9b2bb4a875e62de9c | refs/heads/master | 2021-01-22T21:28:13.982722 | 2017-05-05T07:21:19 | 2017-05-05T07:21:19 | 85,434,828 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,322 | py | class Solution(object):
def paintHouse(self, costs):
if costs == None or len(costs) == 0: return -1
n = len(costs)
for i in range(1,n):
costs[i][0] = costs[i][0] + min(costs[i-1][1], costs[i-1][2])
costs[i][1] = costs[i][1] + min(costs[i-1][0], costs[i-1][2])
... | [
"bch6179@gmail.com"
] | bch6179@gmail.com |
cdff1430959d3feb6893f479095f9de2ba77ae53 | e3dd0254121b8c51b30fad8f494207d7776af5fe | /BOJ/01000/01075.py | 27bfbc64e870d5d8ca06493df02cbf341b47e3bd | [] | no_license | Has3ong/Algorithm | 609d057b10641466b323ce8c4f6e792de1ab5d0b | 83390f2760e54b9b9cf608f3a680f38d5bb5cddc | refs/heads/master | 2020-06-15T03:15:02.908185 | 2019-09-15T16:17:14 | 2019-09-15T16:17:14 | 195,190,040 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 203 | py | def solution():
N = int(input())
F = int(input())
N = (N // 100) * 100
for i in range(100):
M = N + i
if M % F == 0:
break
print(str(M)[-2:])
solution() | [
"khsh5592@naver.com"
] | khsh5592@naver.com |
5b58c08e3876a61c430a35961b7173b43b21a8a3 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_304/ch85_2019_06_06_19_36_38_339098.py | 1a496634416c079b1b60dd94e2c6d2b3b6661571 | [] | no_license | gabriellaec/desoft-analise-exercicios | b77c6999424c5ce7e44086a12589a0ad43d6adca | 01940ab0897aa6005764fc220b900e4d6161d36b | refs/heads/main | 2023-01-31T17:19:42.050628 | 2020-12-16T05:21:31 | 2020-12-16T05:21:31 | 306,735,108 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 253 | py | with open ('macacos-me-mordam.txt', 'r') as arquivo:
conteudo=arquivo.read()
maiusculo=conteudo.upper()
conta_banana=maiusculo.split()
contador=0
for e in conta_banana:
if e == 'BANANA':
contador+=1
print (contador)
| [
"you@example.com"
] | you@example.com |
c35f2ecffbddad9a986f066f6f1b2c9ab404aeda | 0be0bdd8574eda8ec6f0ff340e88bd8677618bb3 | /s01-create-project/meal_options/meal_options/app.py | 01ffc0ddd4b02021af961c76f059fa482d052a55 | [] | no_license | genzj/flask-restful-api-course | 1e97396d6fea50f34922530dc3777393178995c0 | f9ab1bc7da724019dfacc5b94536ec5e8b6afad7 | refs/heads/master | 2023-05-11T06:19:52.307109 | 2022-12-20T20:35:57 | 2022-12-20T20:35:57 | 165,891,710 | 1 | 1 | null | 2023-05-02T00:19:49 | 2019-01-15T17:12:22 | Python | UTF-8 | Python | false | false | 140 | py | from . import create_app
app = create_app()
@app.route("/")
def index():
app.logger.warning("hello world")
return "Hello World!"
| [
"zj0512@gmail.com"
] | zj0512@gmail.com |
902836baed5634be041c938b400c0b355c6b5b0f | 632e8ed762f9f694e8f72d4d65303b5246a11217 | /py/word_count.py | e66f432c740864a91e65bfe0e842bbf04ea07f34 | [] | no_license | yiyusheng/django | 36537bedf7efd2db3e41809c898cdabe2af6c381 | a8a79ef0323cd9234cec83735618940f63dfc2a4 | refs/heads/master | 2022-11-19T11:36:30.868697 | 2022-11-06T04:01:50 | 2022-11-06T04:01:50 | 97,066,542 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,404 | py | # -*- coding: utf-8 -*-
import pymysql,warnings,jieba,sys
import pandas as pd
from datetime import datetime,timedelta
from collections import Counter
# mysql connect
def sqlcon():
conn = pymysql.connect(
host = "localhost",
user = "root",
passwd = "qwer1234",
charset = "utf8",
... | [
"yiyusheng.hust@gmail.com"
] | yiyusheng.hust@gmail.com |
3a4b99682fa6c9d529af4e44480f812cef0d3781 | d2c4934325f5ddd567963e7bd2bdc0673f92bc40 | /tests/artificial/transf_Fisher/trend_ConstantTrend/cycle_5/ar_12/test_artificial_128_Fisher_ConstantTrend_5_12_0.py | 825a6bdaa5c4a8acc661aa02e67ba5736b2b433f | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | jmabry/pyaf | 797acdd585842474ff4ae1d9db5606877252d9b8 | afbc15a851a2445a7824bf255af612dc429265af | refs/heads/master | 2020-03-20T02:14:12.597970 | 2018-12-17T22:08:11 | 2018-12-17T22:08:11 | 137,104,552 | 0 | 0 | BSD-3-Clause | 2018-12-17T22:08:12 | 2018-06-12T17:15:43 | Python | UTF-8 | Python | false | false | 270 | py | import pyaf.Bench.TS_datasets as tsds
import pyaf.tests.artificial.process_artificial_dataset as art
art.process_dataset(N = 128 , FREQ = 'D', seed = 0, trendtype = "ConstantTrend", cycle_length = 5, transform = "Fisher", sigma = 0.0, exog_count = 0, ar_order = 12); | [
"antoine.carme@laposte.net"
] | antoine.carme@laposte.net |
2b3de044fbd1ca7140aa5bd56bb39b86532524cb | b121b4135f0edf0e39c1ae7343c7df19f56a077f | /prototypes/decorators/Fibonacci_Cache_decorator_Class.py | ddb98fbbb340a1ac1a4c0dd94506ff2aa344a4df | [] | no_license | MPIBGC-TEE/bgc-md | 25379c03d2333481bd385211f49aff6351e5dd05 | 8912a26d1b7e404ed3ebee4d4799a3518f507756 | refs/heads/master | 2021-05-08T19:07:46.930394 | 2020-10-21T12:08:53 | 2020-10-21T12:08:53 | 119,548,100 | 3 | 3 | null | null | null | null | UTF-8 | Python | false | false | 389 | py | class Memoize:
def __init__(self,fn):
self.fn=fn
self.memo={}
def __call__(self,*args):
if args not in self.memo:
self.memo[args] = self.fn(*args)
return self.memo[args]
@Memoize
def fib(n):
if n == 0:
return 0
elif n == 1:
re... | [
"markus.mueller.1.g@googlemail.com"
] | markus.mueller.1.g@googlemail.com |
a039f6918e1185e2714bffca130845312af93bae | 163bbb4e0920dedd5941e3edfb2d8706ba75627d | /Code/CodeRecords/2716/60712/321105.py | e2f159e0ba7662e623164f51e9759d7ba83ab298 | [] | no_license | AdamZhouSE/pythonHomework | a25c120b03a158d60aaa9fdc5fb203b1bb377a19 | ffc5606817a666aa6241cfab27364326f5c066ff | refs/heads/master | 2022-11-24T08:05:22.122011 | 2020-07-28T16:21:24 | 2020-07-28T16:21:24 | 259,576,640 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 144 | py | l=[]
for i in range(3):
l.append(input())
if l=='['[', ' "//",', ' "/ "']':
print(3)
elif l==[[0, 0]]:
print(0)
else:
print(l) | [
"1069583789@qq.com"
] | 1069583789@qq.com |
8d1385879e292e12bcc56f1d11b3835812fd8220 | cbbce6a21a57c6a638fc0144f2e4dd9583adb30f | /Estrutura_De_Decisao/estruturadedecisao-13.py | f65664112836ff48a86a6bf5972fb42292eba44c | [] | no_license | gaijinctfx/PythonExercicios | 5d0e0decfe8122b5d07713b33aea66b736700554 | 1e0cde4f27b14ac192e37da210bad3f7023437c7 | refs/heads/master | 2022-05-11T21:57:17.184820 | 2017-06-08T03:21:49 | 2017-06-08T03:21:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,603 | py | # author: ZumbiPy
# E-mail: zumbipy@gmail.com
# Exercicio do site http://wiki.python.org.br/EstruturaDeDecisao
# Para execurta o programa on line entra no link a baixo:
# https://repl.it/I2Ee/0
"""
13 - Faça um Programa que leia um número e exiba o dia correspondente
da semana. (1-Domingo, 2- Segunda, etc.), se digitar... | [
"zumbipy@gmail.com"
] | zumbipy@gmail.com |
41e5ce490aacef1706d7e4fc24123d2a67a90fa1 | 99259216f11b15ec60446b4a141b3592a35560ce | /wex-python-api/ibmwex/models/nlp_document.py | bf8459f2bec05fb8a89b69ac55ae507867f2e20b | [] | no_license | adam725417/Walsin | 296ba868f0837077abff93e4f236c6ee50917c06 | 7fbefb9bb5064dabccf4a7e2bf49d2a43e0f66e9 | refs/heads/master | 2020-04-12T14:14:07.607675 | 2019-03-05T01:54:03 | 2019-03-05T01:54:03 | 162,546,202 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,784 | py | # coding: utf-8
"""
WEX REST APIs
Authentication methods - Basic Auth - JSON Web Token - [POST /api/v1/usermgmt/login](#!/User/signinUser) - [POST /api/v1/usermgmt/logout](#!/User/doLogout) - Python client sample [Download](/docs/wex-python-api.zip)
OpenAPI spec version: 12.0.2.417
Generate... | [
"adamtp_chen@walsin.com"
] | adamtp_chen@walsin.com |
0979f9239fd35acdc47af14483eb5da3f0e0521b | 6ea94d75b6e48952c1df2bda719a886f638ed479 | /devel/lib/python2.7/dist-packages/object_recognition_core/__init__.py | 69401447b8ce90354d2b13050999f5c8523ae0b6 | [] | no_license | lievech/ork_ws | 634e26355503c69b76df7fca41402ea43c228f49 | e828846b962974a038be08a5ce39601b692d4045 | refs/heads/master | 2020-08-02T20:19:43.109158 | 2019-09-28T11:56:56 | 2019-09-28T11:56:56 | 211,493,180 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,018 | py | # -*- coding: utf-8 -*-
# generated from catkin/cmake/template/__init__.py.in
# keep symbol table as clean as possible by deleting all unnecessary symbols
from os import path as os_path
from sys import path as sys_path
from pkgutil import extend_path
__extended_path = "/home/lhn/ork_ws/src/ork_core/python".split(";"... | [
"2328187416@qq.com"
] | 2328187416@qq.com |
3e0e1ee40d064048f3b637b4d1b098ac730d61bc | 3e660e22783e62f19e9b41d28e843158df5bd6ef | /script.me.syncsmashingfromgithub/smashingfavourites/scripts/testscripts/refreshpvrinfo/disableiptvtest1.py | 0b6379f6ab0f50cde1e4ee88d0ded24ceaa8d61e | [] | no_license | monthou66/repository.smashingfavourites | a9603906236000d2424d2283b50130c7a6103966 | f712e2e4715a286ff6bff304ca30bf3ddfaa112f | refs/heads/master | 2020-04-09T12:14:34.470077 | 2018-12-04T10:56:45 | 2018-12-04T10:56:45 | 160,341,386 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,179 | py | # -*- coding: utf-8 -*-
import xbmc
def printstar():
print "***************************************************************************************"
print "****************************************************************************************"
printstar()
print "test1.py has just been started"
printstar()... | [
"davemullane@gmail.com"
] | davemullane@gmail.com |
67eac9c88b11d3565f79cf41ffc9d127d3f4b194 | df9187f1c78cf61075fa23c27432adef0cce285a | /iteratorss/generators_example1.py | 29c46365c6fa1acc2622cad63f8b2dd8c505b5c8 | [] | no_license | santoshr1016/techmonthppt | 6a17c6c7fc97ef7faad9264ed4f89d455e4db100 | cc5e6bce71b3495a6abd2064f74ac8be8c973820 | refs/heads/master | 2020-03-07T00:17:14.395984 | 2018-03-28T14:56:10 | 2018-03-28T14:56:10 | 127,153,491 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 341 | py | def gen_function():
n = 1
print('This is printed first')
yield n
n += 1
print('This is printed second')
yield n
n += 1
print('This is printed at last')
yield n
gen = gen_function()
print(next(gen))
print(next(gen))
print(next(gen))
# using the for loop
# for item in gen_function(... | [
"santy1016@gmail.com"
] | santy1016@gmail.com |
43aba475c1cfef902574ad46c9157de811b4527b | deba1fb8df5fa58563b172546ee06d3c69fb59a8 | /shop_asistant_dj/shop_asistant_dj/apps/purchase/migrations/0005_auto_20200814_1432.py | f954ccf8881328d75cde6ce92c8eeded2d69462d | [] | no_license | korid24/shop_list_via_django | 52d71873fe546ab26a253438ec349c5034211122 | 9426f9305697754c10b402ac7b6e858974d14f96 | refs/heads/master | 2023-01-01T09:30:05.339463 | 2020-10-22T10:03:26 | 2020-10-22T10:03:26 | 289,884,426 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 698 | py | # Generated by Django 3.1 on 2020-08-14 07:32
from django.db import migrations, models
import django.utils.timezone
class Migration(migrations.Migration):
dependencies = [
('purchase', '0004_auto_20200814_1203'),
]
operations = [
migrations.AlterField(
model_name='purchase',... | [
"korid24.dev@gmail.com"
] | korid24.dev@gmail.com |
7d65ca613df3d3dd46ccacae4b6e90189ce005c9 | f3d38d0e1d50234ce5f17948361a50090ea8cddf | /CodeUp/Python 기초 100제/6048번 ; 정수 2개 입력받아 비교하기1.py | 7bc89b85386b03f9c73d7d64141d73bdd23be07a | [] | no_license | bright-night-sky/algorithm_study | 967c512040c183d56c5cd923912a5e8f1c584546 | 8fd46644129e92137a62db657187b9b707d06985 | refs/heads/main | 2023-08-01T10:27:33.857897 | 2021-10-04T14:36:21 | 2021-10-04T14:36:21 | 323,322,211 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 480 | py | # https://codeup.kr/problem.php?id=6048
# readline을 사용하기 위해 import합니다.
from sys import stdin
# 두 정수를 공백으로 구분해 입력합니다.
# 각각 정수형으로 만들어주고 변수에 넣어줍니다.
a, b = map(int, stdin.readline().split(' '))
# a가 b보다 작다면
if a < b:
# True를 출력합니다.
print(True)
# 그렇지 않다면, 즉, a가 b보다 작지 않다면
else:
# False를 출력합니다.
print(Fals... | [
"bright_night_sky@naver.com"
] | bright_night_sky@naver.com |
d0b3d534982c31fb50ebe286974255e9b7a45d14 | 7872b02b8f066fa228bbfa2dd6fcfb5a9ee49dc7 | /tests/dump_tests/module_tests/acl_test.py | 105b948a53f44a84fcc38b9e261f2194e140a4fe | [
"LicenseRef-scancode-generic-cla",
"Apache-2.0"
] | permissive | stephenxs/sonic-utilities | 1d6168206140c5b790cfc1a70cea6a8288040cb0 | c2bc150a6a05c97362d540c874deff81fad6f870 | refs/heads/master | 2023-03-16T05:55:37.688189 | 2023-03-06T18:56:51 | 2023-03-06T18:56:51 | 187,989,457 | 0 | 1 | NOASSERTION | 2023-03-09T13:21:43 | 2019-05-22T07:48:38 | Python | UTF-8 | Python | false | false | 6,227 | py | import os
import pytest
from deepdiff import DeepDiff
from dump.helper import create_template_dict, sort_lists, populate_mock
from dump.plugins.acl_table import Acl_Table
from dump.plugins.acl_rule import Acl_Rule
from dump.match_infra import MatchEngine, ConnectionPool
from swsscommon.swsscommon import SonicV2Connecto... | [
"noreply@github.com"
] | stephenxs.noreply@github.com |
a6df023df1316eb45efd17d0843f1cfed8d86f28 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02412/s889541613.py | 889b2dbcdc586cb5aac3f12cd5a26d0b3e20daca | [] | no_license | Aasthaengg/IBMdataset | 7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901 | f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8 | refs/heads/main | 2023-04-22T10:22:44.763102 | 2021-05-13T17:27:22 | 2021-05-13T17:27:22 | 367,112,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 292 | py | while True:
i = input().split()
n, x = map(int, i)
if n == 0 and x == 0:
break
count = 0
for a in range(1, n+1):
for b in range(a+1, n+1):
for c in range(b+1, n+1):
if a+b+c == x:
count += 1
print(count) | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
20cb167f243d0a2395152f20be419b70fa1a0efd | 8fb16223e667e6bf35e3131ba6ed6bc5e0862fd1 | /src/util/constant.py | eeb5d72b7be93835aeb592492eaeff7f46afdbff | [] | no_license | ydup/robot-personal | 22f07738cde2d84d02d97255aa7c0c2d38537eaf | c7b16091bfbe280d1d92a38a46f7d5bbad55e5db | refs/heads/master | 2020-12-26T16:41:08.208720 | 2020-01-31T17:04:54 | 2020-01-31T17:04:54 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,915 | py | import sys
import os
import random
curPath = os.path.abspath(os.path.dirname(__file__))
rootPath = os.path.split(curPath)[0]
BASE_PATH = os.path.split(rootPath)[0]
sys.path.append(BASE_PATH)
#### Redis Key Begin
# 每个城市单独保存一个key做集合,订阅的用户在集合中
USE_REDIS = False
# 当前所有疫情数据,类型:list
STATE_NCOV_INFO = 'state_ncov_info'
# 所... | [
"maicius@outlook.com"
] | maicius@outlook.com |
6096776bf8dd21fe58ce88a2c47d00d6451aff58 | f576f0ea3725d54bd2551883901b25b863fe6688 | /sdk/purview/azure-mgmt-purview/generated_samples/accounts_list_by_resource_group.py | b8ffb87223d71e319f8cff856c97d022bb768056 | [
"LicenseRef-scancode-generic-cla",
"MIT",
"LGPL-2.1-or-later"
] | permissive | Azure/azure-sdk-for-python | 02e3838e53a33d8ba27e9bcc22bd84e790e4ca7c | c2ca191e736bb06bfbbbc9493e8325763ba990bb | refs/heads/main | 2023-09-06T09:30:13.135012 | 2023-09-06T01:08:06 | 2023-09-06T01:08:06 | 4,127,088 | 4,046 | 2,755 | MIT | 2023-09-14T21:48:49 | 2012-04-24T16:46:12 | Python | UTF-8 | Python | false | false | 1,586 | py | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may ... | [
"noreply@github.com"
] | Azure.noreply@github.com |
53010e1bfd118bc7c2ed2950dc17576e508e457a | 2545624bbbf982aa6243acf8b0cb9f7eaef155d6 | /2019/round_1a/rhyme.py | 28194d837671b486030f48e3044cdf0851600a4f | [] | no_license | dprgarner/codejam | 9f420003fb48c2155bd54942803781a095e984d1 | d7e1134fe3fe850b419aa675260c4ced630731d0 | refs/heads/master | 2021-07-12T05:36:08.465603 | 2021-07-03T12:37:46 | 2021-07-03T12:37:46 | 87,791,734 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,168 | py | """
Codejam boilerplate. Copy/paste this file with get_cases and handle_case
customised.
"""
from os import sys
class BaseInteractiveCaseHandler():
"""
Boilerplate class.
"""
def __init__(self):
self.source = self.get_source()
def get_source(self):
try:
while True:
... | [
"dprgarner@gmail.com"
] | dprgarner@gmail.com |
13f19f5bcf551f3f4499f60bbf7cd5325f1a18a6 | fd21d6384ba36aa83d0c9f05f889bdbf8912551a | /a10sdk/core/gslb/gslb_zone_service_dns_a_record_dns_a_record_srv.py | e6e43c2ee8a7be28521783527603b200e3b349b5 | [
"Apache-2.0"
] | permissive | 0xtobit/a10sdk-python | 32a364684d98c1d56538aaa4ccb0e3a5a87ecd00 | 1ea4886eea3a1609b2ac1f81e7326758d3124dba | refs/heads/master | 2021-01-18T03:08:58.576707 | 2014-12-10T00:31:52 | 2014-12-10T00:31:52 | 34,410,031 | 0 | 0 | null | 2015-04-22T19:05:12 | 2015-04-22T19:05:12 | null | UTF-8 | Python | false | false | 2,598 | py | from a10sdk.common.A10BaseClass import A10BaseClass
class DnsARecordSrv(A10BaseClass):
"""Class Description::
Specify DNS Address Record.
Class dns-a-record-srv supports CRUD Operations and inherits from `common/A10BaseClass`.
This class is the `"PARENT"` class for this module.`
:param as_r... | [
"doug@parksidesoftware.com"
] | doug@parksidesoftware.com |
b9ea48c03deb0ec979884538322f7b48b21f5023 | 62e58c051128baef9452e7e0eb0b5a83367add26 | /edifact/D98B/SUPMAND98BUN.py | ba37762c3029a0327ed8a98c72ab27c2349e27b6 | [] | no_license | dougvanhorn/bots-grammars | 2eb6c0a6b5231c14a6faf194b932aa614809076c | 09db18d9d9bd9d92cefbf00f1c0de1c590fe3d0d | refs/heads/master | 2021-05-16T12:55:58.022904 | 2019-05-17T15:22:23 | 2019-05-17T15:22:23 | 105,274,633 | 0 | 0 | null | 2017-09-29T13:21:21 | 2017-09-29T13:21:21 | null | UTF-8 | Python | false | false | 1,855 | py | #Generated by bots open source edi translator from UN-docs.
from bots.botsconfig import *
from edifact import syntax
from recordsD98BUN import recorddefs
structure = [
{ID: 'UNH', MIN: 1, MAX: 1, LEVEL: [
{ID: 'BGM', MIN: 1, MAX: 1},
{ID: 'RFF', MIN: 1, MAX: 6},
{ID: 'CUX', MIN: 0, MAX: 1},
{ID: 'DTM'... | [
"jason.capriotti@gmail.com"
] | jason.capriotti@gmail.com |
d6be93f57e6800ddb1758330fd39c0ad37c84fdd | 809e8079051ae2a062c4b867654d6fb7b5db722d | /test/export.py | 451c615fd8392dc1982344ca4d0dd46091790b50 | [] | no_license | OpenSourceBrain/TobinEtAl2017 | 035fa4fc490e01c98a22dcb79e707152af5b1288 | 5afd481cdf92197e1438ec483955dae20293dc63 | refs/heads/master | 2020-04-11T23:18:05.057605 | 2019-05-10T13:15:30 | 2019-05-10T13:15:30 | 162,162,576 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 157 | py | from pyneuroml.swc.ExportSWC import convert_to_swc
files = ['bask.cell.nml', 'pyr_4_sym.cell.nml']
for f in files:
convert_to_swc(f, add_comments=True) | [
"p.gleeson@gmail.com"
] | p.gleeson@gmail.com |
a07f19ef5b2f19ab5ca36e897948080c68a05850 | ec7591c3f478c43e76257aaa500d8f6a2e763d74 | /stanza/models/constituency/evaluate_treebanks.py | 11f3084b3413a8f82eef0949f0a8023a1ec187dd | [
"Apache-2.0"
] | permissive | stanfordnlp/stanza | 5cc3dbe70a96dd565639b7dae1efde6b4fa76985 | c530c9af647d521262b56b717bcc38b0cfc5f1b8 | refs/heads/main | 2023-09-01T12:01:38.980322 | 2023-03-14T16:10:05 | 2023-03-14T16:10:05 | 104,854,615 | 4,281 | 599 | NOASSERTION | 2023-09-10T00:31:36 | 2017-09-26T08:00:56 | Python | UTF-8 | Python | false | false | 1,249 | py | """
Read multiple treebanks, score the results.
Reports the k-best score if multiple predicted treebanks are given.
"""
import argparse
from stanza.models.constituency import tree_reader
from stanza.server.parser_eval import EvaluateParser, ParseResult
def main():
parser = argparse.ArgumentParser(description='... | [
"horatio@gmail.com"
] | horatio@gmail.com |
c9b5d98cfab617283e43057e2f975465d57c1fdb | c8fb08292d264780c8cd3ac6734dadf2b15d9818 | /doc/_gallery/plot_2_6_monocomp_nonstat_colored_gaussian_noise.py | c4ab25ebb03cf1fd16656ad864eb6eede8c230f5 | [] | no_license | dhuadaar/pytftb | d2e761ae86053b4a78f494ee3272ca3f4cde05ad | d3f5e99775cb7bc3455440ac19bd80806c47b33f | refs/heads/master | 2021-01-17T22:03:29.804566 | 2016-01-18T06:42:06 | 2016-01-18T06:42:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 796 | py | #! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2015 jaidev <jaidev@newton>
#
# Distributed under terms of the MIT license.
"""
=========================
Noisy Monocomponent Chirp
=========================
This example demonstrates the construction of a monocomponent signal with
linear... | [
"deshpande.jaidev@gmail.com"
] | deshpande.jaidev@gmail.com |
5017780ee6b8321374fe9235fe905cae865ce388 | de01cb554c2292b0fbb79b4d5413a2f6414ea472 | /algorithms/Medium/684.redundant-connection.py | 94b04ed4eec6fe7450dfa43b9c4bf80eac217280 | [] | no_license | h4hany/yeet-the-leet | 98292017eadd3dde98a079aafcd7648aa98701b4 | 563d779467ef5a7cc85cbe954eeaf3c1f5463313 | refs/heads/master | 2022-12-10T08:35:39.830260 | 2020-09-02T23:12:15 | 2020-09-02T23:12:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,934 | py | #
# @lc app=leetcode id=684 lang=python3
#
# [684] Redundant Connection
#
# https://leetcode.com/problems/redundant-connection/description/
#
# algorithms
# Medium (57.63%)
# Total Accepted: 100.8K
# Total Submissions: 174.9K
# Testcase Example: '[[1,2],[1,3],[2,3]]'
#
#
# In this problem, a tree is an undirected ... | [
"kevin.wkmiao@gmail.com"
] | kevin.wkmiao@gmail.com |
3a0f2cb630520d7d754dab75c74fc1a264fc997f | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03378/s701099054.py | 973d6f5da00380a9f78771557ce253738abc986c | [] | no_license | Aasthaengg/IBMdataset | 7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901 | f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8 | refs/heads/main | 2023-04-22T10:22:44.763102 | 2021-05-13T17:27:22 | 2021-05-13T17:27:22 | 367,112,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 222 | py | n, m, x = map(int, input().split())
A = list(map(int, input().split()))
start = 0
end = 0
for i in range(x):
if i in A:
start += 1
for i in range(x,n+1):
if i in A:
end += 1
print(min(start, end)) | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
e8dbd929840258d578174ce40685fd6ebdaa89b1 | f3dbb5b2bdbb4b45bb6548935e7873736c7adc68 | /python/dvalley_core_TestEngineer/.svn/pristine/e8/e8dbd929840258d578174ce40685fd6ebdaa89b1.svn-base | 84058cade8f93e499ed8d350d3df254da5415353 | [] | no_license | lw000/new_python_demo | ece955bdb7df2c5499e4fb582503c13081c89649 | 3ca55b2c3106db75e31676e45e6c5c1f5a6fd714 | refs/heads/master | 2020-03-26T21:09:33.082625 | 2018-08-20T05:37:54 | 2018-08-20T05:37:54 | 145,370,381 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,954 | #!/usr/bin/env python
# -*- coding=utf-8 -*-
'''
Created on 2018年05月31日
@author: Administrator
'''
import sys
import demjson
import logging
import dvcore
from base_api import BaseApi
logging.basicConfig(level=logging.DEBUG)
log = logging.getLogger(__name__)
class UserApi(BaseApi):
de... | [
"liwei@liweideiMac.local"
] | liwei@liweideiMac.local | |
7a99d10927155a58b60057bd7c103dbb1d282c98 | 486a7eda8f492b0607b262d7128c78427b180269 | /src/profileapp/models.py | ddb452673a3cbd06eebbd2af1cc4548f9c766c9f | [] | no_license | Komilcoder/orm | f6d09206d0e9a9b911657cf4c4c3405696d3a39d | 432d7121088aaf53a97a3c12dcf371494262c38a | refs/heads/master | 2023-03-16T06:25:11.561958 | 2021-03-15T07:07:44 | 2021-03-15T07:07:44 | 347,868,830 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,084 | py | from django.db import models
from django.contrib.auth.models import User
class Client(models.Model):
client = models.ForeignKey(User,on_delete=models.CASCADE)
name = models.CharField(max_length=256)
def __str__(self):
return self.name
class Subject(models.Model):
user = models.ForeignKey(... | [
"yaxshilikovkomil@gmail.com"
] | yaxshilikovkomil@gmail.com |
3e02c0db5013c15ac08acaf6e6509dea8a7ff612 | 20f89f49400feb9d2885dc2daf3ea3ca189556e7 | /day05/proctice/三元表达式.py | 5e0bb8bef2856ba4cf186a6e9284acb76a7fb6c2 | [] | no_license | xiaobaiskill/python | 201511b1b1bddec8c33c4efa7ca2cc4afed24a89 | 540693baad757369ff811fb622a949c99fb6b4ba | refs/heads/master | 2021-04-12T03:43:30.308110 | 2018-07-13T01:41:19 | 2018-07-13T01:41:19 | 125,884,001 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 592 | py | #! /usr/bin/env python
# -*- coding:utf-8 -*-
# Author Jmz
'''
语法:
[成立1 if condition1 else
成立2 if condition2 else ...
if 成立N conditionN else 不成立]
'''
sex = 'man'
print('正确' if sex == 'man' else '错误')
# 正确
'''
语句解析:
sex = 'man'
if sex == 'man':
print('正确')
else:
print('错误')
'''
age = 23
res = '猜大了' i... | [
"1125378902@qq.com"
] | 1125378902@qq.com |
c29200633e547e1e14f2c3a49bc8b32333405810 | 86d499787fb35024db798b0c1dbfa7a6936854e9 | /py_tools/example/http_demo/02-根据用户需要返回相应的页面.py | cef6b306a0e0db13d4dc1c3b733418c609ce81ea | [] | no_license | Tomtao626/python-note | afd1c82b74e2d3a488b65742547f75b49a11616e | e498e1e7398ff66a757e161a8b8c32c34c38e561 | refs/heads/main | 2023-04-28T08:47:54.525440 | 2023-04-21T17:27:25 | 2023-04-21T17:27:25 | 552,830,730 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,795 | py | #coding:utf-8
import socket
import re
def service_client(new_socket):
'''为这个客户端返回数据'''
# 接受浏览器发送过来的请求,http请求
request = new_socket.recv(1024)
# print(request)
request_lines = request.splitlines()
print("")
print(">"*20)
print(request_lines)
'''
GET /index.html HTTP/1.1... | [
"gogs@fake.local"
] | gogs@fake.local |
4572a666a39fd92088aeb374ea763180721e82f5 | 16e26dfa651770b51a7879eab5e2ab8d3d6cff92 | /src/data/make_dataset.py | b448390f2975f564afbb864c4610b03a179c80fa | [
"MIT"
] | permissive | carlosgalvez-tiendeo/ue_master-TFM | 108879efc56b01ed64ddbc0346359efcaf66a5e8 | 97ac4d3029b1eef8e95ea8cca846812cafa87d0a | refs/heads/main | 2023-06-09T11:20:59.913197 | 2021-06-23T18:14:00 | 2021-06-23T18:14:00 | 379,906,271 | 0 | 0 | MIT | 2021-06-24T11:45:31 | 2021-06-24T11:45:31 | null | UTF-8 | Python | false | false | 1,476 | py | # -*- coding: utf-8 -*-
import click
import logging
import os
import pandas as pd
from pathlib import Path
from dotenv import find_dotenv, load_dotenv
from sklearn.model_selection import train_test_split
PROJECT_DIR = Path(__file__).resolve().parents[2]
RANDOM_STATE = 288
def get_dataset():
df = pd.read_csv('sr... | [
"carlos.galvez@tiendeo.com"
] | carlos.galvez@tiendeo.com |
decd3605c3e8f3451b507837fc9e80d6e6f84b18 | b659e99f89cf17ae886857383cb5b708847fe3f1 | /Think Python Book/caseStudy-wordPlay/exercise9.3.py | 9014f3fb5e4d0edbc08f63fb7211540e2e2a2b34 | [] | no_license | nitheeshmavila/practice-python | bea06cc4b2b9247b926e07fd5a3987552e531242 | f54bf8934a4cf160cdfc9dc43176f1eea3bc7a41 | refs/heads/master | 2021-07-03T17:24:29.450939 | 2021-06-16T08:40:48 | 2021-06-16T08:40:48 | 100,113,256 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 795 | py | '''
Exercise 9.2
--------------
Write a function named avoids that takes a word and a string of forbidden letters, and
that returns True if the word doesn’t use any of the forbidden letters.
Modify your program to prompt the user to enter a string of forbidden letters and then
print the number of words that don’t conta... | [
"mail2nitheeshmavila@gmail.com"
] | mail2nitheeshmavila@gmail.com |
d84c3a1d543303d754b7448bdcaed968e11c7e93 | 12971fc2b1426f3d3a52039f21c4c2d7bb820f68 | /Exercises4Programmers_57Challenges/01_saying_hello/python/hello_challenge_01.py | dd10b80c3287cb06046aadc6a60c2a3755dfa048 | [
"MIT"
] | permissive | adrianogil/AlgoExercises | 29b3c64e071008bffbfe9273130f980100381deb | be1d8d22eedade2e313458e8d89185452d9da194 | refs/heads/main | 2023-08-18T23:31:51.463767 | 2023-07-22T18:02:46 | 2023-07-22T18:02:46 | 86,254,111 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 457 | py | # The “Hello, World” program is the first program you learn
# to write in many languages, but it doesn’t involve any input.
# So create a program that prompts for your name and prints a greeting using your name.
# Example Output
# What is your name? Brian
# Hello, Brian, nice to meet you!
# Challenge:
# - W... | [
"adrianogil.san@gmail.com"
] | adrianogil.san@gmail.com |
f044703c469fe0463f500e944f0e552a812c0673 | 1d7618d3f1a9ffcabb18caa65d09ea48b632b80b | /tests/opt/projectors/test_proj_lpballs.py | 156fb71b1de5c9cc8e4a0c07b95fb25edf5259ab | [
"Apache-2.0"
] | permissive | carnotresearch/cr-sparse | 668b607f0edd55644db6a879ec6b24a3171b264e | c43496bc54ec32b80b5a64901b04d0a12ac6687f | refs/heads/main | 2023-05-23T19:13:06.283727 | 2022-10-08T06:37:37 | 2022-10-08T06:37:37 | 323,566,858 | 70 | 9 | null | null | null | null | UTF-8 | Python | false | false | 2,337 | py | from projectors_setup import *
# L2 Balls
@pytest.mark.parametrize("x,q,outside", [
[[3,4], 5, 0],
[[3,4], 4, 1],
])
def test_l2_ball(x, q, outside):
ball = projectors.proj_l2_ball(q)
v = ball(x)
if outside:
# second projection should not change it
assert_array_equal(ball(v), v)
... | [
"shailesh@indigits.com"
] | shailesh@indigits.com |
6ffec8c541799771f50bd871e898069f9467c6d2 | 14aa22b09485b40bd1983b6b00f6b8d2f743e0c9 | /120.Triangle/main.py | fea13da0a7ed334583985b15b216c63755b3ffc8 | [] | no_license | ZhihaoJun/leetcode | 02030539815b6353b6a5588c64eebb4a10882b9d | 3cbb3f8ec81aa688ca9d90903a49cdf4a6130c4c | refs/heads/master | 2021-10-25T22:55:45.336738 | 2019-04-08T04:21:41 | 2019-04-08T04:21:41 | 33,469,539 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,066 | py | class Solution(object):
def get(self, x, y):
return self.f[y][x]
def set(self, x, y, v):
if y not in self.f:
self.f[y] = {}
self.f[y][x] = v
def value(self, x, y):
return self.triangle[y][x]
def cal(self, x, y):
if y == self.size-1:
... | [
"zhao11fs@gmail.com"
] | zhao11fs@gmail.com |
56577c16868cd793762ec33a8905362318f541f3 | b3f063ba06a7b4786463cc77756dde766da2b687 | /setup/load_data/load_csv.py | 1f79989374914f1f7d6295fee1dbad5e1dd66a9b | [] | no_license | Lothilius/fun-with-containers | 594b6e9c0470021fc659eda8ef182bb8a0960cc6 | fbc433323f49b13ab13b06aacda0aa57ccbd84b0 | refs/heads/master | 2022-12-22T06:42:34.069508 | 2020-10-06T09:28:30 | 2020-10-06T09:28:30 | 300,806,945 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,521 | py | import pandas as pd
from os import environ
import logging
from sqlalchemy import create_engine
from sqlalchemy.exc import OperationalError
import traceback
import time
logging.basicConfig(level=logging.DEBUG, format='%(asctime)s %(levelname)s:%(message)s')
logger = logging.getLogger(__name__)
def connect_to_db():
... | [
"martin.valenzuela@bazaarvoice.com"
] | martin.valenzuela@bazaarvoice.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.